Преглед изворни кода

Fix: View#detachDomRoot should not throw because NamedNodeMap is not iterable in MS Edge (see ckeditor/ckeditor5#479).

Aleksander Nowodzinski пре 7 година
родитељ
комит
2622511685
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      packages/ckeditor5-engine/src/view/view.js

+ 1 - 1
packages/ckeditor5-engine/src/view/view.js

@@ -275,7 +275,7 @@ export default class View {
 		const domRoot = this.domRoots.get( name );
 
 		// Remove all root attributes so the DOM element is "bare".
-		[ ...domRoot.attributes ].forEach( ( { name } ) => domRoot.removeAttribute( name ) );
+		Array.from( domRoot.attributes ).forEach( ( { name } ) => domRoot.removeAttribute( name ) );
 
 		const initialDomRootAttributes = this._initialDomRootAttributes.get( domRoot );