associating new authorities with the owner roles

This commit is contained in:
kevgliss 2016-01-29 10:59:04 -08:00
parent 39c9a0a299
commit 3cc8ade6d8

View File

@ -101,6 +101,10 @@ def create(kwargs):
database.update(cert)
authority = database.create(authority)
# the owning dl or role should have this authority associated with it
owner_role = role_service.get_by_name(kwargs['ownerEmail'])
owner_role.authority = authority
g.current_user.authorities.append(authority)
return authority