fs: remove unnecessary Function#bind() in fs/promises

PR-URL: https://github.com/nodejs/node/pull/35208
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Masashi Hirano <shisama07@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
This commit is contained in:
Ben Noordhuis authored and Danielle Adams committed 2020-11-09 13:35:03 -05:00
1 parent 9e673723e3
commit ccbe267515
1 file changed
+1 -1
+1 -1
View File
@@ -431,7 +431,7 @@ async function rename(oldPath, newPath) {
async function truncate(path, len = 0) {
const fd = await open(path, 'r+');
return ftruncate(fd, len).finally(fd.close.bind(fd));
return ftruncate(fd, len).finally(fd.close);
}
async function ftruncate(handle, len = 0) {