Refactor gov user check into a decorator

We quite often use it in the same way as `@user_has_permissions`.
This commit is contained in:
Chris Hill-Scott
2018-12-12 13:10:46 +00:00
parent 9a70f6a7f4
commit a8b916b57f
6 changed files with 17 additions and 23 deletions

View File

@@ -5,7 +5,6 @@ from flask_login import AnonymousUserMixin, UserMixin
from app.utils import is_gov_user
roles = {
'send_messages': ['send_texts', 'send_emails', 'send_letters'],
'manage_templates': ['manage_templates'],