summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/src/leap/soledad/common/couch.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/common/src/leap/soledad/common/couch.py b/common/src/leap/soledad/common/couch.py
index 0aa84170..f4696cee 100644
--- a/common/src/leap/soledad/common/couch.py
+++ b/common/src/leap/soledad/common/couch.py
@@ -371,6 +371,7 @@ class CouchDatabase(CommonBackend):
MAX_GET_DOCS_THREADS = 20
update_handler_lock = defaultdict(threading.Lock)
+ sync_info_lock = defaultdict(threading.Lock)
class _GetDocThread(threading.Thread):
"""
@@ -440,7 +441,8 @@ class CouchDatabase(CommonBackend):
if not create:
raise DatabaseDoesNotExist()
server.create(dbname)
- return cls(url, dbname, replica_uid=replica_uid, ensure_ddocs=ensure_ddocs)
+ return cls(
+ url, dbname, replica_uid=replica_uid, ensure_ddocs=ensure_ddocs)
def __init__(self, url, dbname, replica_uid=None, ensure_ddocs=True):
"""
@@ -576,6 +578,8 @@ class CouchDatabase(CommonBackend):
_replica_uid = property(_get_replica_uid, _set_replica_uid)
+ replica_uid = property(_get_replica_uid)
+
def _get_generation(self):
"""
Return the current generation.
@@ -869,7 +873,7 @@ class CouchDatabase(CommonBackend):
# Date.prototype.getTime() which was used before inside a couchdb
# update handler.
(int(time.time() * 1000),
- self._allocate_transaction_id()))
+ self._allocate_transaction_id()))
# build the couch document
couch_doc = {
'_id': doc.doc_id,