GWicke has submitted this change and it was merged.

Change subject: Fixed TemplateHandler to not emit ParserValue tokens + minor 
fixes.
......................................................................


Fixed TemplateHandler to not emit ParserValue tokens + minor fixes.

* Fixed template-expander to correctly handle cases when the
  template-target is not a string.
  - Ignore meta-tokens in the decision-making.
  - When not a string, extract source from parser-value tokens.
* No change in parser tests.
* Eliminates 'Unhandled token' errors from en:Milky way galaxy
  and possibly other pages.

Other fixes:
* Removed length function from ParserValue so it doesn't masquarade
  as an array in if (a.length) type of checks -- ideally we would
  be using explicit if (a.length > 0)
* Set constructor property in ParserValue so we can use checks of
  the type if (a.constructor === ParserValue).
* Updated errCB in parserService to emit stack-trace of error.

Change-Id: I617f2cb28eb8b61f92ea0ea093619bbeb932d8e9
---
M js/api/ParserService.js
M js/lib/ext.core.TemplateHandler.js
M js/lib/mediawiki.HTML5TreeBuilder.node.js
M js/lib/mediawiki.TokenTransformManager.js
M js/lib/mediawiki.parser.defines.js
5 files changed, 46 insertions(+), 29 deletions(-)

Approvals:
  GWicke: Verified; Looks good to me, approved


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

Gerrit-MessageType: merged
Gerrit-Change-Id: I617f2cb28eb8b61f92ea0ea093619bbeb932d8e9
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Parsoid
Gerrit-Branch: master
Gerrit-Owner: Subramanya Sastry <[email protected]>
Gerrit-Reviewer: GWicke <[email protected]>

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

Reply via email to