From 9aaa5e3d44a75c011a6df0791b096e95188e4b6b Mon Sep 17 00:00:00 2001 From: RA80533 <32469082+RA80533@users.noreply.github.com> Date: Sat, 5 Jun 2021 04:14:29 -0400 Subject: [PATCH] docs: use `await` in filehandle.truncate() snippet The example snippet of filehandle.close() uses the `await` keyword based on convention. This change updates the example snippet of filehandle.truncate() to similarly use the keyword for the purposes of consistency. --- doc/api/fs.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/fs.md b/doc/api/fs.md index 72846087466251..2f0ed06a15a97e 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -402,7 +402,7 @@ try { filehandle = await open('temp.txt', 'r+'); await filehandle.truncate(4); } finally { - filehandle?.close(); + await filehandle?.close(); } ```