Description
The Custom Pages module does not properly respect HumHub's permission system. Even when non-admin groups are granted the "Manage custom pages" permission, they cannot access custom page management due to hardcoded isAdmin() checks that bypass the permission system.
Steps to Reproduce
Create a custom group (e.g., "Client Administrator")
Go to Administration → Users → Groups → [Your Group] → Permissions
Grant the group "Custom Pages" → "Manage custom pages" permission
Assign a user to this group
Log in as the user from step 4
Attempt to access custom pages management
Expected Behavior
Users with the "Manage custom pages" permission should be able to:
Access /custom_pages/admin
Create, edit, and delete custom pages
Edit HTML content in custom pages
Actual Behavior
Users get the error: "Oooops... It looks like you may have taken the wrong turn. You cannot manage the page!"
Description
The Custom Pages module does not properly respect HumHub's permission system. Even when non-admin groups are granted the "Manage custom pages" permission, they cannot access custom page management due to hardcoded isAdmin() checks that bypass the permission system.
Steps to Reproduce
Create a custom group (e.g., "Client Administrator")
Go to Administration → Users → Groups → [Your Group] → Permissions
Grant the group "Custom Pages" → "Manage custom pages" permission
Assign a user to this group
Log in as the user from step 4
Attempt to access custom pages management
Expected Behavior
Users with the "Manage custom pages" permission should be able to:
Access /custom_pages/admin
Create, edit, and delete custom pages
Edit HTML content in custom pages
Actual Behavior
Users get the error: "Oooops... It looks like you may have taken the wrong turn. You cannot manage the page!"