jenkins-bot has submitted this change and it was merged. Change subject: Check if newRange is not null ......................................................................
Check if newRange is not null Otherwise uncaught exception. Change-Id: Ia1be5825497d5bd0b9db6045843e8d4466397918 --- M src/ce/ve.ce.Surface.js 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Jforrester: Looks good to me, approved jenkins-bot: Verified diff --git a/src/ce/ve.ce.Surface.js b/src/ce/ve.ce.Surface.js index b4ece3e..32e86c0 100644 --- a/src/ce/ve.ce.Surface.js +++ b/src/ce/ve.ce.Surface.js @@ -2532,7 +2532,7 @@ * @param {ve.Range|null} newRange */ ve.ce.Surface.prototype.onSurfaceObserverRangeChange = function ( oldRange, newRange ) { - if ( !newRange.isCollapsed() && oldRange && oldRange.equalsSelection( newRange ) ) { + if ( newRange && !newRange.isCollapsed() && oldRange && oldRange.equalsSelection( newRange ) ) { // Ignore when the newRange is just a flipped oldRange return; } -- To view, visit https://gerrit.wikimedia.org/r/218643 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ia1be5825497d5bd0b9db6045843e8d4466397918 Gerrit-PatchSet: 1 Gerrit-Project: VisualEditor/VisualEditor Gerrit-Branch: master Gerrit-Owner: Esanders <esand...@wikimedia.org> Gerrit-Reviewer: Catrope <roan.katt...@gmail.com> Gerrit-Reviewer: Divec <da...@sheetmusic.org.uk> Gerrit-Reviewer: Esanders <esand...@wikimedia.org> Gerrit-Reviewer: Jforrester <jforres...@wikimedia.org> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits