move get_all_notifications_for_service and get_all_notifications_for_job

moved from notifications/rest -> service/rest and job/rest respectively
endpoint routes not affected
removed requires_admin decorator - that should be set by nginx config
as opposed to python code
This commit is contained in:
Leo Hemsted
2016-06-28 15:17:36 +01:00
parent 848858f4e4
commit 2b645f490a
8 changed files with 225 additions and 265 deletions

View File

@@ -59,14 +59,3 @@ def fetch_client(client):
"client": client,
"secret": get_unsigned_secrets(client)
}
def require_admin():
def wrap(func):
@wraps(func)
def wrap_func(*args, **kwargs):
if not api_user['client'] == current_app.config.get('ADMIN_CLIENT_USER_NAME'):
abort(403)
return func(*args, **kwargs)
return wrap_func
return wrap