X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=includes%2Fparser%2FParser.php;h=988e2488d8ed22e824e38ba7c9211517079e8456;hp=326100280dd941d3936c810c3a9d8e6c3d610f69;hb=c15f569fcec998b0a77a22a7970abfcb6a394d79;hpb=e687f2da3eb5be95855d9aafc53a7524dfaefa34 diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index 326100280d..988e2488d8 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -736,17 +736,6 @@ class Parser { return $text; } - /** - * Get a random string - * - * @return string - * @deprecated since 1.26; use wfRandomString() instead. - */ - public static function getRandomString() { - wfDeprecated( __METHOD__, '1.26' ); - return wfRandomString( 16 ); - } - /** * Set the current user. * Should only be used when doing pre-save transform. @@ -757,17 +746,6 @@ class Parser { $this->mUser = $user; } - /** - * Accessor for mUniqPrefix. - * - * @return string - * @deprecated since 1.26; use Parser::MARKER_PREFIX instead. - */ - public function uniqPrefix() { - wfDeprecated( __METHOD__, '1.26' ); - return self::MARKER_PREFIX; - } - /** * Set the context title * @@ -973,14 +951,9 @@ class Parser { * @param array $elements List of element names. Comments are always extracted. * @param string $text Source text string. * @param array &$matches Out parameter, Array: extracted tags - * @param string|null $uniq_prefix * @return string Stripped text - * @since 1.26 The uniq_prefix argument is deprecated. */ - public static function extractTagsAndParams( $elements, $text, &$matches, $uniq_prefix = null ) { - if ( $uniq_prefix !== null ) { - wfDeprecated( __METHOD__ . ' called with $prefix argument', '1.26' ); - } + public static function extractTagsAndParams( $elements, $text, &$matches ) { static $n = 1; $stripped = ''; $matches = []; @@ -2611,7 +2584,7 @@ class Parser { ) ) ); break; case 'talkpagename': - if ( $this->mTitle->canTalk() ) { + if ( $this->mTitle->canHaveTalkPage() ) { $talkPage = $this->mTitle->getTalkPage(); $value = wfEscapeWikiText( $talkPage->getPrefixedText() ); } else { @@ -2619,7 +2592,7 @@ class Parser { } break; case 'talkpagenamee': - if ( $this->mTitle->canTalk() ) { + if ( $this->mTitle->canHaveTalkPage() ) { $talkPage = $this->mTitle->getTalkPage(); $value = wfEscapeWikiText( $talkPage->getPrefixedURL() ); } else { @@ -2719,12 +2692,12 @@ class Parser { $value = $this->mTitle->getNamespace(); break; case 'talkspace': - $value = $this->mTitle->canTalk() + $value = $this->mTitle->canHaveTalkPage() ? str_replace( '_', ' ', $this->mTitle->getTalkNsText() ) : ''; break; case 'talkspacee': - $value = $this->mTitle->canTalk() ? wfUrlencode( $this->mTitle->getTalkNsText() ) : ''; + $value = $this->mTitle->canHaveTalkPage() ? wfUrlencode( $this->mTitle->getTalkNsText() ) : ''; break; case 'subjectspace': $value = str_replace( '_', ' ', $this->mTitle->getSubjectNsText() );