Skip to content

Commit c5dc519

Browse files
committed
fix: access buffer
Access the proper object for image rendering.
1 parent 1abee21 commit c5dc519

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/generator.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ export async function generate(app: App,
5858
const binary = Uint8Array.from(atob(base64), c => c.charCodeAt(0));
5959
const lock = app.vault.getFileByPath(path);
6060
if (lock) {
61-
await app.vault.modifyBinary(lock, binary);
61+
await app.vault.modifyBinary(lock, binary.buffer);
6262
} else {
63-
await app.vault.createBinary(path, binary);
63+
await app.vault.createBinary(path, binary.buffer);
6464
}
6565

6666
div.remove();

0 commit comments

Comments
 (0)