return 404 when creating a comment for a non-existing URI

This commit is contained in:
Martin Zimmermann 2013-09-13 16:14:13 +02:00
parent 021b672ee2
commit 2ee47bd902

View File

@ -44,7 +44,7 @@ class requires:
def create(app, environ, request, uri): def create(app, environ, request, uri):
if not utils.urlexists(app.ORIGIN, uri): if not utils.urlexists(app.ORIGIN, uri):
return Response('URI does not exist', 400) return Response('URI does not exist', 404)
try: try:
data = json.loads(request.data) data = json.loads(request.data)