summaryrefslogtreecommitdiff
path: root/src/leap/soledad/server/_blobs.py
diff options
context:
space:
mode:
authorVictor Shyba <victor1984@riseup.net>2017-07-20 04:31:40 -0300
committerdrebs <drebs@leap.se>2017-07-21 10:58:48 -0300
commit961e43404e0d23674360860b04ba5480e752cc94 (patch)
tree575403ebb74f9823df925b1ef166a5d7ac4723c4 /src/leap/soledad/server/_blobs.py
parent76cbf4cbf0876e06d1d8e2839b63dffc13c271dd (diff)
[refactor] error handling and missing headers
Improves error handling, add missing header to __init__.py and remove mkdirs from flags methods. This is a commit from code review on !117.
Diffstat (limited to 'src/leap/soledad/server/_blobs.py')
-rw-r--r--src/leap/soledad/server/_blobs.py8
1 files changed, 0 insertions, 8 deletions
diff --git a/src/leap/soledad/server/_blobs.py b/src/leap/soledad/server/_blobs.py
index 85983bd1..6afd802c 100644
--- a/src/leap/soledad/server/_blobs.py
+++ b/src/leap/soledad/server/_blobs.py
@@ -76,10 +76,6 @@ class FilesystemBlobsBackend(object):
def get_flags(self, user, blob_id, request, namespace=''):
path = self._get_path(user, blob_id, namespace)
- try:
- mkdir_p(os.path.split(path)[0])
- except OSError:
- pass
if not os.path.isfile(path):
# 404 - Not Found
request.setResponseCode(404)
@@ -91,10 +87,6 @@ class FilesystemBlobsBackend(object):
def set_flags(self, user, blob_id, request, namespace=''):
path = self._get_path(user, blob_id, namespace)
- try:
- mkdir_p(os.path.split(path)[0])
- except OSError:
- pass
if not os.path.isfile(path):
# 404 - Not Found
request.setResponseCode(404)