client: Fix console error when exporting SVG after multiple note types

This commit is contained in:
Elian Doran 2024-09-01 23:24:36 +03:00
parent ace237989c
commit 2a6870d73b
No known key found for this signature in database
2 changed files with 2 additions and 2 deletions

View File

@ -134,7 +134,7 @@ export default class MermaidWidget extends NoteContextAwareWidget {
} }
async exportSvgEvent({ntxId}) { async exportSvgEvent({ntxId}) {
if (!this.isNoteContext(ntxId)) { if (!this.isNoteContext(ntxId) || this.note.type !== "mermaid") {
return; return;
} }

View File

@ -110,7 +110,7 @@ export default class MindMapWidget extends TypeWidget {
} }
async exportSvgEvent({ntxId}) { async exportSvgEvent({ntxId}) {
if (!this.isNoteContext(ntxId)) { if (!this.isNoteContext(ntxId) || this.note.type !== "mindMap") {
return; return;
} }