Skip to content
This repository has been archived by the owner on Jun 26, 2020. It is now read-only.

Commit

Permalink
Merge pull request #15 from ckeditor/t/14
Browse files Browse the repository at this point in the history
Fix: Aligned use of converter to the latest API. Closes #14.
  • Loading branch information
oskarwrobel authored Mar 7, 2017
2 parents cf0d73f + df93562 commit 8f98e2b
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/clipboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,7 @@ export default class Clipboard extends Plugin {
// Convert the pasted content to a model document fragment.
// Convertion is contextual, but in this case we need an "all allowed" context and for that
// we use the $clipboardHolder item.
const modelFragment = dataController.viewToModel.convert( data.content, {
context: [ '$clipboardHolder' ]
} );
const modelFragment = dataController.toModel( data.content, '$clipboardHolder' );

doc.enqueueChanges( () => {
dataController.insertContent( modelFragment, doc.selection );
Expand Down

0 comments on commit 8f98e2b

Please sign in to comment.