X-Git-Url: http://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=includes%2FTitle.php;h=90ac89ced80ad7b4dfcf3fa6a182da52ae1e84b6;hp=38ee2eeca46d2a4048127c52729164ab83d06ed9;hb=58cb1f824ac75c3b58ba19d1e88c1b38f9dc1fab;hpb=0cdd5c506357ef5ca7d44213248fe16751218998 diff --git a/includes/Title.php b/includes/Title.php index 38ee2eeca4..90ac89ced8 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -3434,7 +3434,7 @@ class Title implements LinkTarget { * WARNING: do not use this function on arbitrary user-supplied titles! * On heavily-used templates it will max out the memory. * - * @param array $options May be FOR UPDATE + * @param array $options Query option to Database::select() * @return Title[] Array of Title the Title objects linking here */ public function getTemplateLinksTo( $options = [] ) { @@ -3448,7 +3448,7 @@ class Title implements LinkTarget { * WARNING: do not use this function on arbitrary user-supplied titles! * On heavily-used templates it will max out the memory. * - * @param array $options May be FOR UPDATE + * @param array $options Query option to Database::select() * @param string $table Table name * @param string $prefix Fields prefix * @return array Array of Title objects linking here @@ -3461,11 +3461,7 @@ class Title implements LinkTarget { return []; } - if ( count( $options ) > 0 ) { - $db = wfGetDB( DB_MASTER ); - } else { - $db = wfGetDB( DB_SLAVE ); - } + $db = wfGetDB( DB_SLAVE ); $blNamespace = "{$prefix}_namespace"; $blTitle = "{$prefix}_title";