X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiQueryBase.php;h=25053345af615a651fc06bd9c785eb4792448368;hb=e5ef0fd0c6607dd34f6dee69d716b159662a0a34;hp=d955b56d03ea55b83ebec9df8688e08d4a84fe32;hpb=c13fee87d42bdd6fdf6764edb6f6475c14c27749;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiQueryBase.php b/includes/api/ApiQueryBase.php index d955b56d03..25053345af 100644 --- a/includes/api/ApiQueryBase.php +++ b/includes/api/ApiQueryBase.php @@ -423,35 +423,6 @@ abstract class ApiQueryBase extends ApiBase { return Hooks::run( 'ApiQueryBaseProcessRow', [ $this, $row, &$data, &$hookData ] ); } - /** - * @deprecated since 1.33, use LinkFilter::getQueryConditions() instead - * @param string|null $query - * @param string|null $protocol - * @return null|string - */ - public function prepareUrlQuerySearchString( $query = null, $protocol = null ) { - wfDeprecated( __METHOD__, '1.33' ); - $db = $this->getDB(); - if ( $query !== null && $query !== '' ) { - if ( is_null( $protocol ) ) { - $protocol = 'http://'; - } - - $likeQuery = LinkFilter::makeLikeArray( $query, $protocol ); - if ( !$likeQuery ) { - $this->dieWithError( 'apierror-badquery' ); - } - - $likeQuery = LinkFilter::keepOneWildcard( $likeQuery ); - - return 'el_index ' . $db->buildLike( $likeQuery ); - } elseif ( !is_null( $protocol ) ) { - return 'el_index ' . $db->buildLike( "$protocol", $db->anyString() ); - } - - return null; - } - /** * Filters hidden users (where the user doesn't have the right to view them) * Also adds relevant block information @@ -530,7 +501,7 @@ abstract class ApiQueryBase extends ApiBase { /** * Same as addPageSubItems(), but one element of $data at a time * @param int $pageId Page ID - * @param array $item Data array à la ApiResult + * @param mixed $item Data à la ApiResult * @param string|null $elemname XML element name. If null, getModuleName() * is used * @return bool Whether the element fit in the result