diff options
author | 2023-09-13 14:11:18 +0530 | |
---|---|---|
committer | 2023-09-13 01:41:18 -0700 | |
commit | 878b473085f9db2425bb45f0c76dbdf5bb3b4b85 (patch) | |
tree | 668afe809dee25ca6b133056e798a938be34a277 | |
parent | 6161c201e17cb104436b5fe1f0b6b7b069fbe39d (diff) | |
download | bun-878b473085f9db2425bb45f0c76dbdf5bb3b4b85.tar.gz bun-878b473085f9db2425bb45f0c76dbdf5bb3b4b85.tar.zst bun-878b473085f9db2425bb45f0c76dbdf5bb3b4b85.zip |
file.exists() needs to be awaited to get the value (#5061)
-rw-r--r-- | docs/guides/read-file/exists.md | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/guides/read-file/exists.md b/docs/guides/read-file/exists.md index fd6cbbf9a..0359f5728 100644 --- a/docs/guides/read-file/exists.md +++ b/docs/guides/read-file/exists.md @@ -8,7 +8,7 @@ The `Bun.file()` function accepts a path and returns a `BunFile` instance. Use t const path = "/path/to/package.json"; const file = Bun.file(path); -file.exists(); // boolean; +await file.exists(); // boolean; ``` --- |