Subramanya Sastry has uploaded a new change for review.
https://gerrit.wikimedia.org/r/246863
Change subject: Revert "DSR: Remove stale/dead conditions in LTR propagation"
......................................................................
Revert "DSR: Remove stale/dead conditions in LTR propagation"
There is actually a subtle bug here ( a <= b when a is null is still true, but
we don't want that) + this exposed a bug in migrateTrailingNLs pass which is a
separate fix.
This reverts commit dd00a5c8211eec2faf4ffffbefc6a7468797323b.
Change-Id: I1a4cd1e60eab7a5347ae9261a87efa87c046a7b9
---
M lib/dom.computeDSR.js
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid
refs/changes/63/246863/1
diff --git a/lib/dom.computeDSR.js b/lib/dom.computeDSR.js
index c4692a3..5229ffe 100644
--- a/lib/dom.computeDSR.js
+++ b/lib/dom.computeDSR.js
@@ -496,7 +496,7 @@
newCE = newCE +
DU.decodedCommentLength(sibling);
} else if (nType === node.ELEMENT_NODE)
{
var siblingDP =
DU.getDataParsoid(sibling);
- if (siblingDP.dsr &&
siblingDP.dsr[0] <= newCE) {
+ if (siblingDP.dsr &&
siblingDP.tsr && siblingDP.dsr[0] <= newCE && e !== null) {
// sibling's dsr wont
change => ltr propagation stops here.
break;
}
--
To view, visit https://gerrit.wikimedia.org/r/246863
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I1a4cd1e60eab7a5347ae9261a87efa87c046a7b9
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