From 20c770058d81b4fb1ae144ced0d524f96aca1d44 Mon Sep 17 00:00:00 2001 From: Adam Dobrawy Date: Thu, 5 Nov 2020 01:39:42 +0100 Subject: [PATCH] Use promises to writeFile in README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index be8a1d9b05a..7437880dc89 100644 --- a/README.md +++ b/README.md @@ -66,7 +66,7 @@ const ffmpeg = createFFmpeg({ log: true }); await ffmpeg.load(); ffmpeg.FS('writeFile', 'test.avi', await fetchFile('./test.avi')); await ffmpeg.run('-i', 'test.avi', 'test.mp4'); - fs.writeFileSync('./test.mp4', ffmpeg.FS('readFile', 'test.mp4')); + await fs.promises.writeFile('./test.mp4', ffmpeg.FS('readFile', 'test.mp4')); process.exit(0); })(); ```