summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRalph Bean <ralph.bean@gmail.com>2011-04-13 20:57:30 -0400
committerRalph Bean <ralph.bean@gmail.com>2011-04-13 20:57:30 -0400
commit185d81c0eca65f5bbaf269a3a014b5e90943c700 (patch)
tree245c04f401a93bc53195939b7bc23b5ab082b37a
parentfb8a3c11be2f5aae4b4da06fef1adfb2b58c456e (diff)
downloadleafymiracle-185d81c0eca65f5bbaf269a3a014b5e90943c700.zip
leafymiracle-185d81c0eca65f5bbaf269a3a014b5e90943c700.tar.gz
leafymiracle-185d81c0eca65f5bbaf269a3a014b5e90943c700.tar.xz
Fix busted short-circuit to return real webob biz
-rw-r--r--leafymiracle/views.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/leafymiracle/views.py b/leafymiracle/views.py
index 2805e79..65ee626 100644
--- a/leafymiracle/views.py
+++ b/leafymiracle/views.py
@@ -51,7 +51,9 @@ def search(context, request):
# Don't do any search if the term is too short
if len(term) < 2:
- return {'data':[]}
+ resp = webob.Response(request=request, content_type="application/json")
+ resp.body = simplejson.dumps({'data':[]})
+ return resp
attrs = {
'Category' : {