X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fskins%2FBaseTemplate.php;h=02247bd0e00aafb5088ebabb55161fddfd567884;hb=7dddd2f7e20031c53a65a46a5f72e5fd88bf0a7a;hp=64145adb3ad014fe939a7571825f150b2e825fd1;hpb=74d04edec385aa86ee01943b9a27475d79f74e78;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/skins/BaseTemplate.php b/includes/skins/BaseTemplate.php index 64145adb3a..02247bd0e0 100644 --- a/includes/skins/BaseTemplate.php +++ b/includes/skins/BaseTemplate.php @@ -46,7 +46,7 @@ abstract class BaseTemplate extends QuickTemplate { /** * @param string $str * @warning You should never use this method. I18n messages should be escaped - * @deprecated 1.32 Use ->msg() or ->msgWiki() instead. + * @deprecated 1.32 Use ->msg() or ->getMsg() instead. * @suppress SecurityCheck-XSS * @return-taint exec_html */ @@ -55,7 +55,11 @@ abstract class BaseTemplate extends QuickTemplate { echo $this->getMsg( $str )->text(); } + /** + * @deprecated since 1.33 Use ->msg() or ->getMsg() instead. + */ function msgWiki( $str ) { + // TODO: Add wfDeprecated( __METHOD__, '1.33' ) after 1.33 got released echo $this->getMsg( $str )->parseAsBlock(); } @@ -371,11 +375,7 @@ abstract class BaseTemplate extends QuickTemplate { * @return string */ function makeLink( $key, $item, $options = [] ) { - if ( isset( $item['text'] ) ) { - $text = $item['text']; - } else { - $text = wfMessage( $item['msg'] ?? $key )->text(); - } + $text = $item['text'] ?? wfMessage( $item['msg'] ?? $key )->text(); $html = htmlspecialchars( $text );