Hoo man has uploaded a new change for review.
https://gerrit.wikimedia.org/r/65958
Change subject: Allow patrolling page creations from Special:RecentChanges
......................................................................
Allow patrolling page creations from Special:RecentChanges
In case we got a page creation which is yet unpatrolled and
recent changes patrolling is enabled, the user probably rather
wants to patrol the whole page (first revision) instead of seeing
a patrollink for the current revision.
Follow up to I1e24733c
Bug: 48928
Change-Id: I9f89f1d44852d4c03a67ac622d5cf4d86453dce3
---
M includes/ChangesList.php
1 file changed, 10 insertions(+), 2 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/58/65958/1
diff --git a/includes/ChangesList.php b/includes/ChangesList.php
index 796b92a..f2d1533 100644
--- a/includes/ChangesList.php
+++ b/includes/ChangesList.php
@@ -362,10 +362,18 @@
* @param $watched
*/
public function insertArticleLink( &$s, &$rc, $unpatrolled, $watched ) {
- # If it's a new article, there is no diff link, but if it
hasn't been
- # patrolled yet, we need to give users a way to do so
+ global $wgUseRCPatrol;
+
$params = array();
+ // In case we got a page creation which is yet unpatrolled and
+ // recent changes patrolling is enabled, the user probably
rather
+ // wants to patrol the whole page (first revision) instead of
seeing
+ // a patrollink for the current revision.
+ if ( $wgUseRCPatrol && $unpatrolled && $rc->getAttribute(
'rc_type' ) == RC_NEW ) {
+ $params['patrolpage'] = 1;
+ }
+
$articlelink = Linker::linkKnown(
$rc->getTitle(),
null,
--
To view, visit https://gerrit.wikimedia.org/r/65958
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I9f89f1d44852d4c03a67ac622d5cf4d86453dce3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Hoo man <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits