Skip to content

Commit 3726a4d

Browse files
committed
refactor: replace Deno.readTextFile with fs.readFile
1 parent c78f749 commit 3726a4d

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/runner.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { Exercise } from "./exercise.ts";
2+
import { readFile } from "node:fs/promises";
23

34
interface RunResult {
45
ok: boolean;
@@ -26,7 +27,7 @@ const check = async (exercise: Exercise): Promise<RunResult> => {
2627
};
2728

2829
const isDone = async (exercise: Exercise): Promise<boolean> => {
29-
return !(await Deno.readTextFile(exercise.path)).includes("// I AM NOT DONE");
30+
return !(await readFile(exercise.path, "utf-8")).includes("// I AM NOT DONE");
3031
};
3132

3233
export { check, isDone };

0 commit comments

Comments
 (0)