Fix syntax terror from r79884
[lhc/web/wiklou.git] / includes / Skin.php
index f94903c..c88e8a0 100644 (file)
@@ -484,7 +484,7 @@ class Skin extends Linker {
         * You will only be adding bloat to the page and causing page caches to have to be purged on configuration changes.
         */
        static function makeGlobalVariablesScript( $skinName ) {
-               global $wgTitle, $wgUser, $wgRequest, $wgArticle, $wgOut, $wgRestrictionTypes, $wgUseAjax, $wgEnableMWSuggest;
+               global $wgTitle, $wgUser, $wgRequest, $wgArticle, $wgOut, $wgUseAjax, $wgEnableMWSuggest;
                
                $ns = $wgTitle->getNamespace();
                $nsname = MWNamespace::exists( $ns ) ? MWNamespace::getCanonicalName( $ns ) : $wgTitle->getNsText();
@@ -504,7 +504,7 @@ class Skin extends Linker {
                        'wgCategories' => $wgOut->getCategories(),
                        'wgBreakFrames' => $wgOut->getFrameOptions() == 'DENY',
                );
-               foreach ( $wgRestrictionTypes as $type ) {
+               foreach ( $wgTitle->getRestrictionTypes() as $type ) {
                        $vars['wgRestriction' . ucfirst( $type )] = $wgTitle->getRestrictions( $type );
                }
                if ( $wgUseAjax && $wgEnableMWSuggest && !$wgUser->getOption( 'disablesuggest', false ) ) {
@@ -1566,9 +1566,7 @@ class Skin extends Linker {
                // Allow for site and per-namespace customization of copyright notice.
                $forContent = true;
 
-               if ( isset( $wgArticle ) ) {
-                       wfRunHooks( 'SkinCopyrightFooter', array( $wgArticle->getTitle(), $type, &$msg, &$link, &$forContent ) );
-               }
+               wfRunHooks( 'SkinCopyrightFooter', array( $this->mTitle, $type, &$msg, &$link, &$forContent ) );
 
                if ( $forContent ) {
                        $out .= wfMsgForContent( $msg, $link );