summaryrefslogtreecommitdiff
path: root/client/src
diff options
context:
space:
mode:
authorVictor Shyba <victor1984@riseup.net>2017-03-22 17:09:26 -0300
committerdrebs <drebs@leap.se>2017-03-31 18:58:56 +0200
commit6067f8c001d524d29ccc4287a5f2efec90fa5004 (patch)
tree2ba8891629efb4be43966f57d8bee179552b7204 /client/src
parent4cbef63b206d4ab18cbc46a896f2fb24a31844a1 (diff)
[feature] raise earlier when deleting None
If an application tries to delete None, by accident, raising earlier would help to show the caller stack trace instead of inner sqlite backend stack and make the error more friendly. - Resolves: #8791
Diffstat (limited to 'client/src')
-rw-r--r--client/src/leap/soledad/client/api.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/client/src/leap/soledad/client/api.py b/client/src/leap/soledad/client/api.py
index 23f8570e..36423e39 100644
--- a/client/src/leap/soledad/client/api.py
+++ b/client/src/leap/soledad/client/api.py
@@ -347,6 +347,7 @@ class Soledad(object):
:return: A deferred.
:rtype: twisted.internet.defer.Deferred
"""
+ soledad_assert(doc is not None, "delete_doc doesn't accept None.")
return self._defer("delete_doc", doc)
def get_doc(self, doc_id, include_deleted=False):