$undoMsg = 'norev';
}
- // Give grep a chance to find the usages: undo-success, undo-failure, undo-norev
+ // Messages: undo-success, undo-failure, undo-norev
$class = ( $undoMsg == 'success' ? '' : 'error ' ) . "mw-undo-{$undoMsg}";
$this->editFormPageTop .= $wgOut->parse( "<div class=\"{$class}\">" .
wfMessage( 'undo-' . $undoMsg )->plain() . '</div>', true, /* interface */true );
wfProfileOut( __METHOD__ );
return $status;
}
- if ( $wgUser->pingLimiter() ) {
+ if ( $wgUser->pingLimiter() || $wgUser->pingLimiter( 'linkpurge', 0 ) ) {
$status->fatal( 'actionthrottledtext' );
$status->value = self::AS_RATE_LIMITED;
wfProfileOut( __METHOD__ . '-checks' );
}
$result['nullEdit'] = $doEditStatus->hasMessage( 'edit-no-change' );
+ if ( $result['nullEdit'] ) {
+ // We don't know if it was a null edit until now, so increment here
+ $wgUser->pingLimiter( 'linkpurge' );
+ }
$result['redirect'] = $content->isRedirect();
$this->updateWatchlist();
wfProfileOut( __METHOD__ );