Jackmcbarn has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/141048

Change subject: Handle PTD_FOR_INCLUSION properly
......................................................................

Handle PTD_FOR_INCLUSION properly

Change handling of PTD_FOR_INCLUSION to match that of the parser (i.e.,
don't set it if text is being expanded in the root frame).

Change-Id: I13f45e57aa334642d310e9bd5fdd3dbe5922c4e1
---
M engines/LuaCommon/LuaCommon.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Scribunto 
refs/changes/48/141048/1

diff --git a/engines/LuaCommon/LuaCommon.php b/engines/LuaCommon/LuaCommon.php
index 30bab14..c89f303 100644
--- a/engines/LuaCommon/LuaCommon.php
+++ b/engines/LuaCommon/LuaCommon.php
@@ -648,7 +648,7 @@
                if ( !isset( $this->expandCache[$hash] ) ) {
                        if ( is_scalar( $input ) ) {
                                $dom = 
$this->parser->getPreprocessor()->preprocessToObj( 
-                                       $input, Parser::PTD_FOR_INCLUSION );
+                                       $input, $frame->depth ? 
Parser::PTD_FOR_INCLUSION : 0 );
                        } else {
                                $dom = $input;
                        }

-- 
To view, visit https://gerrit.wikimedia.org/r/141048
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I13f45e57aa334642d310e9bd5fdd3dbe5922c4e1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Scribunto
Gerrit-Branch: master
Gerrit-Owner: Jackmcbarn <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to