mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-24 12:21:22 -05:00
Make sure users always have permission to access top-level templates
This commit is contained in:
@@ -155,6 +155,10 @@ class User(UserMixin):
|
||||
if self.platform_admin:
|
||||
return True
|
||||
|
||||
# Top-level templates are always visible
|
||||
if template_folder is None:
|
||||
return True
|
||||
|
||||
return self.id in template_folder.get("users_with_permission", [])
|
||||
|
||||
def belongs_to_service(self, service_id):
|
||||
|
||||
Reference in New Issue
Block a user