mahara-contributors team mailing list archive
-
mahara-contributors team
-
Mailing list archive
-
Message #15006
[Bug 1250302] Re: A site admin who belongs to an institution with skins disabled, gets an error trying to edit site skins
I'm not sure what the best way to proceed with this is. The previous
patch for Bug 1249123 resolved the issue by making it so that if you're
an admin, "can_use_skins()" always returns true. This gets rid of the
error messages, but it has the unfortunate side effect of also allowing
site admins to use skins in their personal pages, regardless of the
settings for the institution they belong to. I can easily see this
causing problems when admins think that skins are turned on for all
users, when in fact they're only turned on for the admins.
One alternative is to change every page so that it checks whether you're
editing a site page before it calls can_use_skins(). But this is ugly
and kind of error-prone.
A third option, is to parameterize can_use_skins(). Pass in a parameter
that indicates whether you're working on a normal page or a site page,
and use that to determine the answer. I think that's probably the way we
should go.
--
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1250302
Title:
A site admin who belongs to an institution with skins disabled, gets
an error trying to edit site skins
Status in Mahara ePortfolio:
New
Bug description:
To replicate:
1. Set $cfg->skins = true; in your config.php to enable skins
2. Disable skins for at least one institution, by using the institution configuration screen
3. Log in as a site admin who belongs to that institution
4. Navigate to "Configure site -> Skins".
5. Click on "Create skin"
Expected result: You should be able to create a skin
Actual result: You see a "feature not available" exception
To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1250302/+subscriptions
References