Przeglądaj źródła

Cannot based on checking the "#document" property on view elements because it always be defined.

Kamil Piechaczek 6 lat temu
rodzic
commit
6118ab5116

+ 1 - 1
packages/ckeditor5-engine/src/conversion/downcasthelpers.js

@@ -544,7 +544,7 @@ export function clearAttributes() {
 			// Not collapsed selection should not have artifacts.
 			if ( range.isCollapsed ) {
 				// Position might be in the node removed by the view writer.
-				if ( range.end.parent.document ) {
+				if ( range.end.parent.parent ) {
 					conversionApi.writer.mergeAttributes( range.start );
 				}
 			}