summaryrefslogtreecommitdiff
path: root/ext/node/polyfills
diff options
context:
space:
mode:
Diffstat (limited to 'ext/node/polyfills')
-rw-r--r--ext/node/polyfills/_fs/_fs_fdatasync.ts5
1 files changed, 3 insertions, 2 deletions
diff --git a/ext/node/polyfills/_fs/_fs_fdatasync.ts b/ext/node/polyfills/_fs/_fs_fdatasync.ts
index f6ed4a39b..482b4378c 100644
--- a/ext/node/polyfills/_fs/_fs_fdatasync.ts
+++ b/ext/node/polyfills/_fs/_fs_fdatasync.ts
@@ -4,14 +4,15 @@
// deno-lint-ignore-file prefer-primordials
import { CallbackWithError } from "ext:deno_node/_fs/_fs_common.ts";
+import { FsFile } from "ext:deno_fs/30_fs.js";
export function fdatasync(
fd: number,
callback: CallbackWithError,
) {
- Deno.fdatasync(fd).then(() => callback(null), callback);
+ new FsFile(fd).dataSync().then(() => callback(null), callback);
}
export function fdatasyncSync(fd: number) {
- Deno.fdatasyncSync(fd);
+ new FsFile(fd).dataSyncSync();
}