From: Brion Vibber Date: Sat, 22 Jan 2005 06:11:10 +0000 (+0000) Subject: Avoid notice error when user doesn't have right to move a page. X-Git-Tag: 1.5.0alpha1~870 X-Git-Url: http://git.cyclocoop.org/%28?a=commitdiff_plain;h=9be9e5117cb36c4357cd120a8bc8d89439d47b42;p=lhc%2Fweb%2Fwiklou.git Avoid notice error when user doesn't have right to move a page. --- diff --git a/includes/Skin.php b/includes/Skin.php index ea29fd85fe..1b60a942b4 100644 --- a/includes/Skin.php +++ b/includes/Skin.php @@ -1026,10 +1026,12 @@ class Skin extends Linker { global $wgTitle, $wgContLang; if ( $wgTitle->userCanMove() ) { - $s = $this->makeKnownLink( $wgContLang->specialPage( 'Movepage' ), + return $this->makeKnownLink( $wgContLang->specialPage( 'Movepage' ), wfMsg( 'movethispage' ), 'target=' . $wgTitle->getPrefixedURL() ); - } // no message if page is protected - would be redundant - return $s; + } else { + // no message if page is protected - would be redundant + return ''; + } } function historyLink() {