Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(63)

Unified Diff: chrome/common/extensions/docs/server2/servlet.py

Issue 736773002: Docserver: Add commit history and _reset_commit servlet (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Cleanup, test for commit reset Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/docs/server2/servlet.py
diff --git a/chrome/common/extensions/docs/server2/servlet.py b/chrome/common/extensions/docs/server2/servlet.py
index 5465d81b57be10ec9ef898aaad0ab64c97bf5865..61917fffae6c0be93bcfab742c486702e27ccd06 100644
--- a/chrome/common/extensions/docs/server2/servlet.py
+++ b/chrome/common/extensions/docs/server2/servlet.py
@@ -96,6 +96,12 @@ class Response(object):
return Response(headers={'Location': url}, status=status)
@staticmethod
+ def BadRequest(content, headers=None):
+ '''Returns a bad request (400) response.
+ '''
+ return Response(content=content, headers=headers, status=400)
+
+ @staticmethod
def NotFound(content, headers=None):
'''Returns a not found (404) response.
'''

Powered by Google App Engine
This is Rietveld 408576698