jenkins-bot has submitted this change and it was merged.

Change subject: SourceSurfaceFragment: Check range is not collapsed
......................................................................


SourceSurfaceFragment: Check range is not collapsed

Change-Id: Ib70b24e3dbe120fc90f4ab79341821c468220b2d
---
M src/dm/ve.dm.SourceSurfaceFragment.js
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Jforrester: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/dm/ve.dm.SourceSurfaceFragment.js 
b/src/dm/ve.dm.SourceSurfaceFragment.js
index bc8a5af..72f39da 100644
--- a/src/dm/ve.dm.SourceSurfaceFragment.js
+++ b/src/dm/ve.dm.SourceSurfaceFragment.js
@@ -30,7 +30,7 @@
                originalDocument = this.getDocument(),
                coveringRange = this.getSelection().getCoveringRange();
 
-       if ( coveringRange ) {
+       if ( !coveringRange.isCollapsed() ) {
                tempDocument = originalDocument.shallowCloneFromRange( 
coveringRange );
                rangeInDocument = tempDocument.originalRange;
        } else {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib70b24e3dbe120fc90f4ab79341821c468220b2d
Gerrit-PatchSet: 2
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: 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

Reply via email to