mirror of
https://github.com/pretix/pretix.git
synced 2026-08-29 13:44:40 +00:00
More legacy compat
This commit is contained in:
@@ -418,6 +418,9 @@ class Team(LoggedModel):
|
||||
if self.all_event_permissions or all(self.limit_event_permissions.get(kk) for kk in v):
|
||||
result.add(k)
|
||||
|
||||
if "can_change_event_settings" in result:
|
||||
result.add("can_change_settings")
|
||||
|
||||
return result
|
||||
|
||||
def organizer_permission_set(self, include_legacy=True) -> set:
|
||||
|
||||
@@ -121,6 +121,8 @@ def get_all_organizer_permissions() -> Set[str]:
|
||||
|
||||
|
||||
def assert_valid_event_permission(permission, allow_legacy=True, allow_tuple=True):
|
||||
if allow_legacy and permission == "can_change_settings":
|
||||
permission = "can_change_event_settings"
|
||||
if permission is None:
|
||||
return
|
||||
if isinstance(permission, (list, tuple)) and allow_tuple:
|
||||
|
||||
Reference in New Issue
Block a user