Remove retroactive editor permission fallback

This commit is contained in:
Jage9
2026-02-27 03:54:02 -05:00
parent 181ab22a80
commit 7c0ddf99d1

View File

@@ -856,12 +856,6 @@ class AuthService:
else: else:
existing = self._db_fetchall("SELECT permission_key FROM role_permissions WHERE role_id = ?", (role_id,)) existing = self._db_fetchall("SELECT permission_key FROM role_permissions WHERE role_id = ?", (role_id,))
if existing: if existing:
if role_name == "editor":
# Keep existing editor customizations but ensure own pickup/drop is present.
self._db_execute(
"INSERT OR IGNORE INTO role_permissions (role_id, permission_key) VALUES (?, ?)",
(role_id, "item.pickup_drop.own"),
)
# Preserve existing customizations for non-admin defaults. # Preserve existing customizations for non-admin defaults.
continue continue
allowed = DEFAULT_ROLE_PERMISSIONS.get(role_name, set()) allowed = DEFAULT_ROLE_PERMISSIONS.get(role_name, set())