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

Unified Diff: appengine/findit/handlers/config.py

Issue 1836293002: [Findit] Adding central config test class for unit tests (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Rebase Created 4 years, 8 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
« no previous file with comments | « no previous file | appengine/findit/handlers/test/build_failure_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: appengine/findit/handlers/config.py
diff --git a/appengine/findit/handlers/config.py b/appengine/findit/handlers/config.py
index 74883848bcde94072804cf7e2e4331020df83f12..e65f52e94f06cb78cc997e5ce66c84a34f4675fa 100644
--- a/appengine/findit/handlers/config.py
+++ b/appengine/findit/handlers/config.py
@@ -11,6 +11,8 @@ from base_handler import Permission
from model import wf_config
from waterfall import waterfall_config
+from google.appengine.api import users
+
def _RemoveDuplicatesAndSort(elements):
return list(set(elements))
@@ -243,6 +245,8 @@ class Configuration(BaseHandler):
return self.CreateError(
'New configuration settings is not properly formatted.', 400)
- wf_config.FinditConfig.Get().Update(**new_config_dict)
+ wf_config.FinditConfig.Get().Update(users.get_current_user(),
+ users.IsCurrentUserAdmin(),
+ **new_config_dict)
return self.HandleGet()
« no previous file with comments | « no previous file | appengine/findit/handlers/test/build_failure_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698