Nikerabbit has submitted this change and it was merged.

Change subject: Avoid using User::getSkin()
......................................................................


Avoid using User::getSkin()

Change-Id: I205c1809a10bf83f5781c8d5f3e6f281b83e3545
---
M LinkPage.php
M SpecialLinkRedirect.php
2 files changed, 6 insertions(+), 6 deletions(-)

Approvals:
  Nikerabbit: Verified; Looks good to me, approved



diff --git a/LinkPage.php b/LinkPage.php
index 29132d8..65cb85e 100644
--- a/LinkPage.php
+++ b/LinkPage.php
@@ -50,9 +50,9 @@
        }
 
        function view() {
-               global $wgOut, $wgUser, $wgLinkPageDisplay;
+               global $wgOut, $wgLinkPageDisplay;
 
-               $sk = $wgUser->getSkin();
+               $sk = $wgOut->getSkin();
 
                $wgOut->setHTMLTitle( $this->getTitle()->getText() );
                $wgOut->setPageTitle( $this->getTitle()->getText() );
@@ -426,4 +426,4 @@
 
                return $output;
        }
-}
\ No newline at end of file
+}
diff --git a/SpecialLinkRedirect.php b/SpecialLinkRedirect.php
index e9db749..0d08bd4 100644
--- a/SpecialLinkRedirect.php
+++ b/SpecialLinkRedirect.php
@@ -17,16 +17,16 @@
        public function execute( $par ) {
                $out = $this->getOutput();
                $out->setArticleBodyOnly( true );
-               $sk = $this->getUser()->getSkin();
+               $sk = $this->getOutput()->getSkin();
                $url = $this->getRequest()->getVal( 'url' );
                $out->addHTML(
                        "<html>
                                <body onload=window.location=\"{$url}\">
-                               {$sk->bottomScripts( $out )}
+                               {$sk->bottomScripts()}
                                </body>
                        </html>"
                );
 
                return '';
        }
-}
\ No newline at end of file
+}

-- 
To view, visit https://gerrit.wikimedia.org/r/106926
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I205c1809a10bf83f5781c8d5f3e6f281b83e3545
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/LinkFilter
Gerrit-Branch: master
Gerrit-Owner: Siebrand <siebr...@wikimedia.org>
Gerrit-Reviewer: Nikerabbit <niklas.laxst...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to