Subramanya Sastry has uploaded a new change for review.
https://gerrit.wikimedia.org/r/234932
Change subject: Prevent sanitizer from crashing: Followup on faa2bde47
......................................................................
Prevent sanitizer from crashing: Followup on faa2bde47
Assertion in getWTSource is triggering in some scenarios.
This patch prevents that -- the actual assertion failure needs
a separate investigation.
Change-Id: I379a22c647b62a737557b4d0d201d2875e3cd740
---
M lib/ext.core.Sanitizer.js
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid
refs/changes/32/234932/1
diff --git a/lib/ext.core.Sanitizer.js b/lib/ext.core.Sanitizer.js
index 08e952b..f30c1eb 100644
--- a/lib/ext.core.Sanitizer.js
+++ b/lib/ext.core.Sanitizer.js
@@ -711,7 +711,7 @@
) { // unknown tag -- convert to plain text
var origToken = token;
- if (!this.options.inTemplate) {
+ if (!this.options.inTemplate && token.dataAttribs.tsr) {
// Just get the original token source, so that we can
avoid
// whitespace differences.
token = token.getWTSource(this.manager.env);
--
To view, visit https://gerrit.wikimedia.org/r/234932
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I379a22c647b62a737557b4d0d201d2875e3cd740
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Subramanya Sastry <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits