diff options
| author | Ryan Dahl <ry@tinyclouds.org> | 2020-02-25 09:14:27 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-02-25 09:14:27 -0500 |
| commit | 91b606aaae23bcb790b55adc5fe70a182a37d564 (patch) | |
| tree | 16b56a21ffcb3991569eda984fbd14073bdbd3ae /cli/js/utime.ts | |
| parent | 805992b14a65a6dbfb857dea6d9b657477de043d (diff) | |
Clean up how we use opIds (#4118)
Diffstat (limited to 'cli/js/utime.ts')
| -rw-r--r-- | cli/js/utime.ts | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/cli/js/utime.ts b/cli/js/utime.ts index c96461b2c..d80b8b396 100644 --- a/cli/js/utime.ts +++ b/cli/js/utime.ts @@ -1,6 +1,5 @@ // Copyright 2018-2020 the Deno authors. All rights reserved. MIT license. import { sendSync, sendAsync } from "./dispatch_json.ts"; -import { OP_UTIME } from "./dispatch.ts"; function toSecondsFromEpoch(v: number | Date): number { return v instanceof Date ? v.valueOf() / 1000 : v; @@ -17,7 +16,7 @@ export function utimeSync( atime: number | Date, mtime: number | Date ): void { - sendSync(OP_UTIME, { + sendSync("op_utime", { filename, // TODO(ry) split atime, mtime into [seconds, nanoseconds] tuple atime: toSecondsFromEpoch(atime), @@ -36,7 +35,7 @@ export async function utime( atime: number | Date, mtime: number | Date ): Promise<void> { - await sendAsync(OP_UTIME, { + await sendAsync("op_utime", { filename, // TODO(ry) split atime, mtime into [seconds, nanoseconds] tuple atime: toSecondsFromEpoch(atime), |
