mirror of
https://github.com/priyanshujain/margin.git
synced 2026-10-02 11:07:04 +00:00
app store scripts
This commit is contained in:
1 parent
585933c8a1
commit
e8772e6699
6 files changed
+134
-15
No files matched your search
+2
-2
@@ -30,10 +30,10 @@ export async function loadBook(id: string): Promise<Book> {
|
||||
try {
|
||||
book = JSON.parse(contents) as Book;
|
||||
} catch {
|
||||
throw new Error("the book file is corrupt or unreadable");
|
||||
throw new Error("the project file is corrupt or unreadable");
|
||||
}
|
||||
if (schemaVersion(book.schema) > SCHEMA_VERSION) {
|
||||
throw new Error("this book was made with a newer version of Margin; update the app to open it");
|
||||
throw new Error("this project was made with a newer version of Margin; update the app to open it");
|
||||
}
|
||||
return book;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user