Better error message

This commit is contained in:
Jonatan Heyman 2024-07-25 13:21:28 +02:00
parent 03db1efd2f
commit 44aed5feb0

View File

@ -177,7 +177,7 @@ export class HeynoteEditor {
this.setReadOnly(false)
} catch (e) {
this.setReadOnly(true)
throw e
throw new Error(`Failed to load note: ${e.message}`)
}
this.notesStore.currentNoteName = this.note.metadata?.name || this.path
return new Promise((resolve) => {