Revision: 43581
Author:   charlie
Date:     2008-11-16 20:57:21 +0000 (Sun, 16 Nov 2008)

Log Message:
-----------
Added a new user right called "alwaysuseskin" that allows the user to
use and set their configured skin even if the wiki administrator has
chosen to disable user skins for the rest of the wiki. Req. by Alexfusco5.

Modified Paths:
--------------
    trunk/phase3/includes/User.php
    trunk/phase3/includes/specials/SpecialPreferences.php

Modified: trunk/phase3/includes/User.php
===================================================================
--- trunk/phase3/includes/User.php      2008-11-16 19:20:44 UTC (rev 43580)
+++ trunk/phase3/includes/User.php      2008-11-16 20:57:21 UTC (rev 43581)
@@ -2109,7 +2109,7 @@
                if ( ! isset( $this->mSkin ) ) {
                        wfProfileIn( __METHOD__ );
 
-                       if( $wgAllowUserSkin ) {
+                       if( $wgAllowUserSkin || $this->isAllowed( 
'alwaysuseskin' ) ) {
                                # get the user skin
                                $userSkin = $this->getOption( 'skin' );
                                $userSkin = $wgRequest->getVal('useskin', 
$userSkin);

Modified: trunk/phase3/includes/specials/SpecialPreferences.php
===================================================================
--- trunk/phase3/includes/specials/SpecialPreferences.php       2008-11-16 
19:20:44 UTC (rev 43580)
+++ trunk/phase3/includes/specials/SpecialPreferences.php       2008-11-16 
20:57:21 UTC (rev 43581)
@@ -269,7 +269,7 @@
                $wgUser->setOption( 'nickname', $this->mNick );
                $wgUser->setOption( 'quickbar', $this->mQuickbar );
                global $wgAllowUserSkin;
-               if( $wgAllowUserSkin ) {
+               if( $wgAllowUserSkin || $wgUser->isAllowed( 'alwaysuseskin' ) ) 
{
                        $wgUser->setOption( 'skin', $this->mSkin );
                }
                global $wgUseTeX;



_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to