Updated do_badger to take an optional set of roles.

The 'role' parameter now must be passed as keyword arg instead of
positional arg. Either 'role' or 'roles' must be given.
This commit is contained in:
2017-08-22 16:37:47 +02:00
parent 15de24214a
commit 87afbc52f6
3 changed files with 34 additions and 15 deletions

View File

@@ -85,7 +85,7 @@ def badger(action, user_email, role):
with current_app.app_context():
service.fetch_role_to_group_id_map()
response, status = service.do_badger(action, role, user_email=user_email)
response, status = service.do_badger(action, role=role, user_email=user_email)
if status == 204:
log.info('Done.')