Wrong handler onInsertText in slate-drop-or-paste-images
beautyfree opened this issue · 0 comments
beautyfree commented
What's the current behavior?
Wrong handler onInsertText in slate-drop-or-paste-images
In code we have call:
asyncApplyChange(c, editor, file)
But the method accepts only such variables:
function asyncApplyChange(change, file) {
const { editor } = change
return Promise.resolve(insertImage(change, file)).then(() => {
editor.onChange(change)
})
}
So we need to remove editor
from arguments, because we have it in change