The test was intended to check for whether we have a user ID *or* a user
name. Instead, it's checking if we have a user ID *and* a user name. And
it also failed to consider User:0.
Bug: T227656
Change-Id: Ia1b5c4a6ae028513b73a65cd2c885459327d29c3
) {
$userId = $rev->getUser( Revision::FOR_THIS_USER );
$userText = $rev->getUserText( Revision::FOR_THIS_USER );
- if ( $userId && $userText ) {
+ if ( $userId || (string)$userText !== '' ) {
$link = self::userLink( $userId, $userText )
. self::userToolLinks( $userId, $userText, false, 0, null,
$useParentheses );