(bug 19818) - Allow users to patrol edits to user CSS/JS subpages even if they can...
authorAlex Z <mrzman@users.mediawiki.org>
Mon, 20 Jul 2009 05:14:35 +0000 (05:14 +0000)
committerAlex Z <mrzman@users.mediawiki.org>
Mon, 20 Jul 2009 05:14:35 +0000 (05:14 +0000)
RELEASE-NOTES
includes/Title.php

index 7d9e4d8..bd7f1b2 100644 (file)
@@ -302,6 +302,8 @@ this. Was used when mwEmbed was going to be an extension.
 * (bug 19445) Change oldimage table to use ON UPDATE CASCADE for FK to image table.
 * (bug 14080) Short notation links to subpages didn't work in edit summaries
 * (bug 17374) Special:Export no longer exports multiple copies of pages
+* (bug 19818) Edits to user CSS/JS subpages can now be marked as patrolled by
+  users who can't edit them
 
 == API changes in 1.16 ==
 
index 0aaaa8d..0051360 100644 (file)
@@ -1281,7 +1281,7 @@ class Title {
                # Protect css/js subpages of user pages
                # XXX: this might be better using restrictions
                # XXX: Find a way to work around the php bug that prevents using $this->userCanEditCssJsSubpage() from working
-               if( $this->isCssJsSubpage() && !$user->isAllowed('editusercssjs')
+               if( $this->isCssJsSubpage() && !$user->isAllowed('editusercssjs' ) && $action != 'patrol'
                        && !preg_match('/^'.preg_quote($user->getName(), '/').'\//', $this->mTextform) )
                {
                        $errors[] = array('customcssjsprotected');