From d6f3c25084f2bd8ebcb52e357b8b62fded08db32 Mon Sep 17 00:00:00 2001 From: alexej-d Date: Tue, 4 Jun 2019 15:47:14 +0200 Subject: [PATCH] Fix deprecation warning As of slate@0.47, the `getNodesAtRange` method has been renamed to `getDescendantsAtRange`. --- packages/slate-lists/src/commands/unwrap-list.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/slate-lists/src/commands/unwrap-list.js b/packages/slate-lists/src/commands/unwrap-list.js index 9877a97..6590f94 100644 --- a/packages/slate-lists/src/commands/unwrap-list.js +++ b/packages/slate-lists/src/commands/unwrap-list.js @@ -2,7 +2,7 @@ import unwrapListByKey from "./unwrap-list-by-key"; export default ({ blocks }, editor) => { const listItemChildren = editor.value.document - .getNodesAtRange(editor.value.selection) + .getDescendantsAtRange(editor.value.selection) .filter(node => node.type == blocks.list_item_child); const furthestListItems = listItemChildren