X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fsite%2FMediaWikiPageNameNormalizer.php;h=a81ddca924887fc9ecce89b00a6a0f834a7e60e6;hb=b328ae4a4ec1e87261f3b4d554f9bb9073c1c6aa;hp=3e073f088266d936120f2d90b4962b50badf68fc;hpb=0df357b9137ac96ebb6d59bccb99ba9c4680bf46;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/site/MediaWikiPageNameNormalizer.php b/includes/site/MediaWikiPageNameNormalizer.php index 3e073f0882..a81ddca924 100644 --- a/includes/site/MediaWikiPageNameNormalizer.php +++ b/includes/site/MediaWikiPageNameNormalizer.php @@ -26,7 +26,7 @@ use UtfNormal\Validator; * * @since 1.27 * - * @license GNU GPL v2+ + * @license GPL-2.0-or-later * @author John Erling Blad < jeblad@gmail.com > * @author Daniel Kinzler * @author Jeroen De Dauw < jeroendedauw@gmail.com > @@ -54,6 +54,7 @@ class MediaWikiPageNameNormalizer { * Returns the normalized form of the given page title, using the * normalization rules of the given site. If the given title is a redirect, * the redirect will be resolved and the redirect target is returned. + * Only titles of existing pages will be returned. * * @note This actually makes an API request to the remote site, so beware * that this function is slow and depends on an external service. @@ -65,7 +66,9 @@ class MediaWikiPageNameNormalizer { * @param string $pageName * @param string $apiUrl * - * @return string|false + * @return string|false The normalized form of the title, + * or false to indicate an invalid title, a missing page, + * or some other kind of error. * @throws \MWException */ public function normalizePageName( $pageName, $apiUrl ) {