diff --git a/src/core/AiEditor.ts b/src/core/AiEditor.ts index 4d5df45..1247c10 100644 --- a/src/core/AiEditor.ts +++ b/src/core/AiEditor.ts @@ -252,7 +252,7 @@ export class AiEditor { let extensions = getExtensions(this, this.options); if (this.options.onCreateBefore) { const newExtensions = this.options.onCreateBefore(this, extensions); - if (!newExtensions) extensions = newExtensions!; + if (newExtensions) extensions = newExtensions; } this.innerEditor = new InnerEditor(this, {