From: daniel Date: Fri, 8 Jun 2012 07:03:18 +0000 (+0200) Subject: use Content::getWikitextForTransclusion() when fetching template text X-Git-Tag: 1.31.0-rc.0~22097^2^2~136 X-Git-Url: http://git.cyclocoop.org//%27%40script%40/%27?a=commitdiff_plain;h=e259164d156e1efae90ccefc17903876aaa44658;p=lhc%2Fweb%2Fwiklou.git use Content::getWikitextForTransclusion() when fetching template text --- diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index 35f187f4d8..6232bce1af 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -3552,7 +3552,13 @@ class Parser { } if ( $rev ) { - $text = $rev->getText(); + $content = $rev->getContent(); + $text = $content->getWikitextForTransclusion(); + + if ( $text === false || $text === null ) { + $text = false; + break; + } } elseif ( $title->getNamespace() == NS_MEDIAWIKI ) { global $wgContLang; $message = wfMessage( $wgContLang->lcfirst( $title->getText() ) )->inContentLanguage();