Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/sugar_network/db/routes.py
diff options
context:
space:
mode:
authorAleksey Lim <alsroot@sugarlabs.org>2014-04-29 01:46:33 (GMT)
committer Aleksey Lim <alsroot@sugarlabs.org>2014-04-29 01:46:33 (GMT)
commit686643208fd9363487f0c89c53440db9d7fd42b3 (patch)
treee1a48ea6319356931092a673d0f8f0ac5def70a1 /sugar_network/db/routes.py
parent0438dbe5fba595a11a77c5a311512e48cb9cad33 (diff)
Fix file-less blobs behaviour
Diffstat (limited to 'sugar_network/db/routes.py')
-rw-r--r--sugar_network/db/routes.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/sugar_network/db/routes.py b/sugar_network/db/routes.py
index 0ea1305..4c29780 100644
--- a/sugar_network/db/routes.py
+++ b/sugar_network/db/routes.py
@@ -81,7 +81,9 @@ class Routes(object):
def find(self, reply, limit):
self._preget()
request = this.request
- if self._find_limit and limit > self._find_limit:
+ if not limit:
+ request['limit'] = self._find_limit
+ elif self._find_limit and limit > self._find_limit:
_logger.warning('The find limit is restricted to %s',
self._find_limit)
request['limit'] = self._find_limit
@@ -168,7 +170,7 @@ class Routes(object):
@fallbackroute('GET', ['blobs'])
def blobs(self):
- return self.volume.blobs.get(this.request.guid)
+ return self.volume.blobs.get(this.request.path[1:])
@contextmanager
def _post(self, access):