Merge "Revert "(bug 51640) wgUserNewMsgRevisionId is null with only one rev""

This commit is contained in:
jenkins-bot 2013-07-30 20:47:16 +00:00 committed by Gerrit Code Review
commit 347cdf3247
2 changed files with 2 additions and 2 deletions

View file

@ -643,7 +643,7 @@ class EchoHooks {
// Load the styles for the Notifications badge
$out->addModuleStyles( 'ext.echo.badge' );
}
if ( $wgEchoNewMsgAlert && $user->isLoggedIn() && $user->getOption( 'echo-show-alert' ) && $user->getNewtalk() ) {
if ( $wgEchoNewMsgAlert && $user->isLoggedIn() && $user->getOption( 'echo-show-alert' ) ) {
$out->addModules( array( 'ext.echo.alert' ) );
}
return true;

View file

@ -1,6 +1,6 @@
( function ( $, mw ) {
'use strict';
if ( !mw.config.get( 'echoNewMsgAlertDisplayed' ) ) {
if ( mw.config.get( 'wgUserNewMsgRevisionId' ) && !mw.config.get( 'echoNewMsgAlertDisplayed' ) ) {
var alertMessage = mw.html.escape( mw.msg( 'colon-separator' ) + mw.msg( 'echo-new-messages' ) );
$( '#pt-mytalk a' ).append( alertMessage );
$( '#pt-mytalk a' ).addClass( 'mw-echo-alert' );