We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Here you're calling isFile directly on the return of fs.stat. fs.stat is an asynchronous function, that returns a Promise<fs.Stats>. isFile is a property on fs.Stats objects. So, calling isFile on the promise is not valid -- the promise needs to be resolved first.
isFile
fs.stat
Promise<fs.Stats>
fs.Stats
This could be fixed by awaiting the result of fs.stat:
var stat = await fs.stat(path, _);
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Here you're calling
isFile
directly on the return offs.stat
.fs.stat
is an asynchronous function, that returns aPromise<fs.Stats>
.isFile
is a property onfs.Stats
objects. So, callingisFile
on the promise is not valid -- the promise needs to be resolved first.This could be fixed by awaiting the result of
fs.stat
:The text was updated successfully, but these errors were encountered: