mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-24 07:54:13 +00:00
Merge "Revert "(bug 51640) wgUserNewMsgRevisionId is null with only one rev""
This commit is contained in:
commit
347cdf3247
|
@ -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;
|
||||
|
|
|
@ -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' );
|
||||
|
|
Loading…
Reference in a new issue