* Removed broken wgAllowAnonymousMinor and added new group right minoredit
* (bug 4457) Update for Portuguese language (pt)
* convertPlural breakage fixed a little
+* Bug 4456: Add hook for marking article patrolled
=== Caveats ===
'LogPageLogHeader': strings used by wfMsg as a header.
$headerText: array of strings
+'MarkPatrolled': before an edit is marked patrolled
+$rcid: ID of the revision to be marked patrolled
+$user: the user (object) marking the revision as patrolled
+$wcOnlySysopsCanPatrol: config setting indicating whether the user
+ needs to be a sysop in order to mark an edit patrolled
+
+'MarkPatrolledComplete': after an edit is marked patrolled
+$rcid: ID of the revision marked as patrolled
+$user: user (object) who marked the edit patrolled
+$wcOnlySysopsCanPatrol: config setting indicating whether the user
+ must be a sysop to patrol the edit
+
'PageRenderingHash': alter the parser cache option hash key
A parser extension which depends on user options should install
this hook and append its values to the key.
$rcid = $wgRequest->getVal( 'rcid' );
if ( !is_null ( $rcid ) )
{
- RecentChange::markPatrolled( $rcid );
- $wgOut->setPagetitle( wfMsg( 'markedaspatrolled' ) );
- $wgOut->addWikiText( wfMsg( 'markedaspatrolledtext' ) );
-
+ if( wfRunHooks( 'MarkPatrolled', array( &$rcid, &$wgUser, $wgOnlySysopsCanPatrol ) ) ) {
+ RecentChange::markPatrolled( $rcid );
+ wfRunHooks( 'MarkPatrolledComplete', array( &$rcid, &$wgUser, $wgOnlySysopsCanPatrol ) );
+ $wgOut->setPagetitle( wfMsg( 'markedaspatrolled' ) );
+ $wgOut->addWikiText( wfMsg( 'markedaspatrolledtext' ) );
+ }
$rcTitle = Title::makeTitle( NS_SPECIAL, 'Recentchanges' );
$wgOut->returnToMain( false, $rcTitle->getPrefixedText() );
}