Skip to content

Commit

Permalink
fix(tauri.js) writeFile and writeBinaryFile API (#857)
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasfernog committed Jul 19, 2020
1 parent da99f63 commit cbd14c3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changes/fix-fs-api.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"tauri.js": patch
---

Fixes the `writeFile` and `writeBinaryFile` usage.
4 changes: 2 additions & 2 deletions cli/tauri.js/api-src/fs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ async function writeFile(file: FsTextFileOption, options: FsOptions = {}): Promi

return await promisified({
cmd: 'writeFile',
file: file.path,
path: file.path,
contents: file.contents,
options
})
Expand Down Expand Up @@ -155,7 +155,7 @@ async function writeBinaryFile(file: FsBinaryFileOption, options: FsOptions = {}

return await promisified({
cmd: 'writeFile',
file: file.path,
path: file.path,
contents: arrayBufferToBase64(file.contents),
options
})
Expand Down

0 comments on commit cbd14c3

Please sign in to comment.