Merge "Add protection for User: JSON pages in the same manner as JS & CSS ones"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Thu, 29 Mar 2018 14:49:25 +0000 (14:49 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Thu, 29 Mar 2018 14:49:25 +0000 (14:49 +0000)
includes/GlobalFunctions.php
includes/libs/rdbms/lbfactory/LBFactory.php
includes/specials/SpecialWhatlinkshere.php
resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.SaveFiltersPopupButtonWidget.js
resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.SavedLinksListWidget.js

index 42a6573..513f593 100644 (file)
@@ -3019,7 +3019,7 @@ function wfWaitForSlaves(
        $ifWritesSince = null, $wiki = false, $cluster = false, $timeout = null
 ) {
        if ( $timeout === null ) {
-               $timeout = wfIsCLI() ? 86400 : 10;
+               $timeout = wfIsCLI() ? 60 : 10;
        }
 
        if ( $cluster === '*' ) {
index 32886e2..bc428ec 100644 (file)
@@ -313,7 +313,7 @@ abstract class LBFactory implements ILBFactory {
                $opts += [
                        'domain' => false,
                        'cluster' => false,
-                       'timeout' => 60,
+                       'timeout' => $this->cliMode ? 60 : 10,
                        'ifWritesSince' => null
                ];
 
index 6f91c46..3080fbf 100644 (file)
@@ -162,7 +162,7 @@ class SpecialWhatLinksHere extends IncludableSpecialPage {
                        ];
                        $on['rd_namespace'] = $target->getNamespace();
                        // Inner LIMIT is 2X in case of stale backlinks with wrong namespaces
-                       $subQuery = $dbr->selectSQLText(
+                       $subQuery = $dbr->buildSelectSubquery(
                                [ $table, 'redirect', 'page' ],
                                [ $fromCol, 'rd_from' ],
                                $conds[$table],
@@ -175,7 +175,7 @@ class SpecialWhatLinksHere extends IncludableSpecialPage {
                                ]
                        );
                        return $dbr->select(
-                               [ 'page', 'temp_backlink_range' => "($subQuery)" ],
+                               [ 'page', 'temp_backlink_range' => $subQuery ],
                                [ 'page_id', 'page_namespace', 'page_title', 'rd_from', 'page_is_redirect' ],
                                [],
                                __CLASS__ . '::showIndirectLinks',
index f546d97..89ad382 100644 (file)
@@ -25,7 +25,7 @@
                // Parent
                mw.rcfilters.ui.SaveFiltersPopupButtonWidget.parent.call( this, $.extend( {
                        framed: false,
-                       icon: 'unClip',
+                       icon: 'bookmark',
                        title: mw.msg( 'rcfilters-savedqueries-add-new-title' ),
                        popup: {
                                classes: [ 'mw-rcfilters-ui-saveFiltersPopupButtonWidget-popup' ],
@@ -36,7 +36,7 @@
                        }
                }, config ) );
                // // HACK: Add an icon to the popup head label
-               this.popup.$head.prepend( ( new OO.ui.IconWidget( { icon: 'unClip' } ) ).$element );
+               this.popup.$head.prepend( ( new OO.ui.IconWidget( { icon: 'bookmark' } ) ).$element );
 
                this.input = new OO.ui.TextInputWidget( {
                        placeholder: mw.msg( 'rcfilters-savedqueries-new-name-placeholder' )
index 7077434..088aa5b 100644 (file)
@@ -34,7 +34,7 @@
                this.placeholderItem = new OO.ui.DecoratedOptionWidget( {
                        classes: [ 'mw-rcfilters-ui-savedLinksListWidget-placeholder' ],
                        label: $labelNoEntries,
-                       icon: 'unClip'
+                       icon: 'bookmark'
                } );
 
                this.menu = new mw.rcfilters.ui.GroupWidget( {
@@ -50,7 +50,7 @@
                this.button = new OO.ui.PopupButtonWidget( {
                        classes: [ 'mw-rcfilters-ui-savedLinksListWidget-button' ],
                        label: mw.msg( 'rcfilters-quickfilters' ),
-                       icon: 'unClip',
+                       icon: 'bookmark',
                        indicator: 'down',
                        $overlay: this.$overlay,
                        popup: {