fixed infinite-loop because editor.isDestroyed would return invalid return

This commit is contained in:
Dominik Biedebach 2025-04-23 15:37:49 +02:00
parent b70c4531dc
commit 631b0cc90f

View File

@ -718,7 +718,7 @@ export class Editor extends EventEmitter<EditorEvents> {
* Check if the editor is already destroyed.
*/
public get isDestroyed(): boolean {
return !this.editorView?.isDestroyed
return this.editorView?.isDestroyed || false
}
public $node(selector: string, attributes?: { [key: string]: any }): NodePos | null {