From: Tobias Date: Sun, 6 Sep 2009 23:34:58 +0000 (+0000) Subject: fixing error in r55903 - User object from userid is now used instead of wgUser (curre... X-Git-Tag: 1.31.0-rc.0~39890 X-Git-Url: https://git.cyclocoop.org/%27.WWW_URL.%27admin/?a=commitdiff_plain;h=703ec973e87ca8f535dedc50cdc915c656781ad0;p=lhc%2Fweb%2Fwiklou.git fixing error in r55903 - User object from userid is now used instead of wgUser (current user). Also: minor change --- diff --git a/includes/specials/SpecialContributions.php b/includes/specials/SpecialContributions.php index f6f81d042d..ce621a33db 100644 --- a/includes/specials/SpecialContributions.php +++ b/includes/specials/SpecialContributions.php @@ -162,7 +162,7 @@ class SpecialContributions extends SpecialPage { $tools[] = $sk->link( $talk, wfMsgHtml( 'sp-contributions-talk' ) ); if( ( $id != 0 && $wgSysopUserBans ) || ( $id == 0 && IP::isIPAddress( $nt->getText() ) ) ) { if( $wgUser->isAllowed( 'block' ) ) { # Block / Change block / Unblock links - if ( $wgUser->isBlocked() ) { + if ( User::newFromId( $id )->isBlocked() ) { $tools[] = $sk->linkKnown( # Change block link SpecialPage::getTitleFor( 'Blockip', $nt->getDBkey() ), wfMsgHtml( 'change-blocklink' ) @@ -174,8 +174,7 @@ class SpecialContributions extends SpecialPage { array( 'action' => 'unblock', 'ip' => $nt->getDBkey() - ), - array( 'known' ) + ) ); } else { # User is not blocked