Javascript used to look just for the patrollinks class, which
could be set by the user in order to patrol an arbitrary page.
Bug: T103239
Change-Id: I13fcc3ce479c0a4a90a6217c2e5244f051eaf862
Signed-off-by: Chad Horohoe <chadh@wikimedia.org>
if ( !$linkInfo ) {
$this->mMarkPatrolledLink = '';
} else {
- $this->mMarkPatrolledLink = ' <span class="patrollink">[' . Linker::linkKnown(
+ $this->mMarkPatrolledLink = ' <span class="patrollink" data-mw="interface">[' . Linker::linkKnown(
$this->mNewPage,
$this->msg( 'markaspatrolleddiff' )->escaped(),
[],
);
$outputPage->addHTML(
- "<div class='patrollink'>" .
+ "<div class='patrollink' data-mw='interface'>" .
wfMessage( 'markaspatrolledlink' )->rawParams( $link )->escaped() .
'</div>'
);
return;
}
$( function () {
- var $patrolLinks = $( '.patrollink a' );
+ var $patrolLinks = $( '.patrollink[data-mw="interface"] a' );
$patrolLinks.on( 'click', function ( e ) {
var $spinner, rcid, apiRequest;