r96773 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r96772‎ | r96773 | r96774 >
Date:08:14, 11 September 2011
Author:ialex
Status:ok
Tags:
Comment:
* Follow-up r96420: don't show e-mail links to anon users
* Fix for r24612 (!) spotted while fixing the above: parenthesis arround the bitwise check are needed since ! operator has higher precedence than &
Modified paths:
  • /trunk/phase3/includes/Linker.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Linker.php
@@ -941,8 +941,8 @@
942942 ) {
943943 global $wgUser, $wgDisableAnonTalk, $wgLang;
944944 $talkable = !( $wgDisableAnonTalk && 0 == $userId );
945 - $blockable = !$flags & self::TOOL_LINKS_NOBLOCK;
946 - $addEmailLink = $flags & self::TOOL_LINKS_EMAIL;
 945+ $blockable = !( $flags & self::TOOL_LINKS_NOBLOCK );
 946+ $addEmailLink = $flags & self::TOOL_LINKS_EMAIL && $userId;
947947
948948 $items = array();
949949 if ( $talkable ) {

Follow-up revisions

RevisionCommit summaryAuthorDate
r968581.17wmf1: MFT r96430, r96449, r96773reedy16:25, 12 September 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r24612* (bug 10655) Show standard tool links for blocked users in block log messages...robchurch07:09, 6 August 2007
r96420Add constant Linker::TOOL_LINKS_EMAIL to allow adding a "send e-mail" link fr...siebrand12:12, 7 September 2011

Status & tagging log