mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-23 23:44:53 +00:00
Don't ping from user talk links in summary
As discussed at T189034 Change-Id: I86f36ab55c0e03ba3bbd2ea1ee94ce3056d91e30
This commit is contained in:
parent
c63f321cae
commit
6f6e5062fe
|
@ -39,7 +39,7 @@ class EchoSummaryParser {
|
||||||
$title = Title::newFromText( $match );
|
$title = Title::newFromText( $match );
|
||||||
if ( $title
|
if ( $title
|
||||||
&& $title->isLocal()
|
&& $title->isLocal()
|
||||||
&& ( $title->getNamespace() === NS_USER || $title->getNamespace() == NS_USER_TALK )
|
&& $title->getNamespace() === NS_USER
|
||||||
) {
|
) {
|
||||||
$user = User::newFromName( $title->getText() );
|
$user = User::newFromName( $title->getText() );
|
||||||
$lookup = $this->userLookup;
|
$lookup = $this->userLookup;
|
||||||
|
|
|
@ -50,6 +50,7 @@ class EchoSummaryParserTest extends MediaWikiTestCase {
|
||||||
[ '[[:|test]]', [] ],
|
[ '[[:|test]]', [] ],
|
||||||
[ '[[User:Nonexistent]]', [] ],
|
[ '[[User:Nonexistent]]', [] ],
|
||||||
[ '/* [[User:Werdna */', [] ],
|
[ '/* [[User:Werdna */', [] ],
|
||||||
|
[ '[[User talk:Werdna]]', [] ],
|
||||||
[ '[[User:Werdna]]', [ 'Werdna' ] ],
|
[ '[[User:Werdna]]', [ 'Werdna' ] ],
|
||||||
[ 'this is [[ [[User:Werdna]] ]]', [ 'Werdna' ] ],
|
[ 'this is [[ [[User:Werdna]] ]]', [ 'Werdna' ] ],
|
||||||
[ '[[User:Werdna|]]', [ 'Werdna' ] ],
|
[ '[[User:Werdna|]]', [ 'Werdna' ] ],
|
||||||
|
|
Loading…
Reference in a new issue