Jelajahi Sumber

Merge t/ckeditor5-engine/1208

Other: Aligned code to the changes in the engine.
Piotrek Koszuliński 8 tahun lalu
induk
melakukan
09759fd735

+ 1 - 1
packages/ckeditor5-upload/src/imageuploadcommand.js

@@ -57,7 +57,7 @@ export default class ImageUploadCommand extends Command {
 				insertAtSelection = doc.selection;
 			}
 
-			editor.data.insertContent( imageElement, insertAtSelection );
+			editor.model.insertContent( imageElement, insertAtSelection );
 
 			// Inserting an image might've failed due to schema regulations.
 			if ( imageElement.parent ) {

+ 1 - 1
packages/ckeditor5-upload/src/utils.js

@@ -29,7 +29,7 @@ export function isImageType( file ) {
  * position after this paragraph will be returned.
  *
  * Note: If selection is placed in an empty block, that block will be returned. If that position
- * is then passed to {@link module:engine/controller/datacontroller~DataController#insertContent}
+ * is then passed to {@link module:engine/model/model~Model#insertContent}
  * that block will be fully replaced by the image.
  *
  * @param {module:engine/model/selection~Selection} selection Selection based on which the