1. WAKAYAMA shirou
  2. dipus

Commits

WAKAYAMA shirou  committed f3bc1d4

change forbidden to int.

  • Participants
  • Parent commits 28c4092
  • Branches default

Comments (0)

Files changed (1)

File src/dipus/websetup.py

View file
     ''' return index list '''
     password = request.forms.get('password')
     if auth(password) is False:
-        abort("Forbidden")
+        abort(403)
 
     ret = {
         "list": docstore.listindex(conf.indexroot)
 
 
 
+
 @app.route('/<_index>', method='POST')
 def updateDocument(_index):
     password = request.forms.get('password')
 
     if auth(password) is False:
-        abort("Forbidden")
+        abort(403)
 
     path = request.forms.get('path')
     if not path:
 def query(_index):
     password = request.forms.get('password')
     if auth(password) is False:
-        abort("Forbidden")
+        abort(403)
 
     query = request.query.get('q')
 
         "hits": results
         }
 
-
     json_response = simplejson.dumps(ret)
     response.content_type = 'application/json; charset=utf-8'