summaryrefslogtreecommitdiff
path: root/common/src/leap/soledad
diff options
context:
space:
mode:
Diffstat (limited to 'common/src/leap/soledad')
-rw-r--r--common/src/leap/soledad/common/couch.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/common/src/leap/soledad/common/couch.py b/common/src/leap/soledad/common/couch.py
index 3b0e042a..4caaf48f 100644
--- a/common/src/leap/soledad/common/couch.py
+++ b/common/src/leap/soledad/common/couch.py
@@ -29,6 +29,7 @@ import socket
from u1db.backends import CommonBackend, CommonSyncTarget
+from u1db.remote import http_app
from u1db.remote.server_state import ServerState
from u1db import (
errors,
@@ -159,6 +160,10 @@ class CouchDocument(SoledadDocument):
couch_rev = property(_get_couch_rev, _set_couch_rev)
+# monkey-patch the u1db http app to use CouchDocument
+http_app.Document = CouchDocument
+
+
class CouchDatabase(CommonBackend):
"""
A U1DB implementation that uses CouchDB as its persistence layer.