Showing the changes to apps/server/src/workspace/WorkspaceFileSystem.ts (1 of 71 files). Show all
Unified · Split
| @@ -7,7 +7,7 @@ · 6 unmodified lines | ||
| 7 | 7 | * |
| 8 | 8 | * @module WorkspaceFileSystem |
| 9 | 9 | */ |
| 10 | −import { open, realpath } from "node:fs/promises"; | |
| 10 | +import * as NodeFSP from "node:fs/promises"; | |
| 11 | 11 | |
| 12 | 12 | import type { |
| 13 | 13 | ProjectReadFileInput, |
| @@ -89,8 +89,8 @@ export const make = Effect.gen(function* () { · 75 unmodified lines | ||
| 89 | 89 | return yield* Effect.tryPromise({ |
| 90 | 90 | try: async () => { |
| 91 | 91 | const [realWorkspaceRoot, realTargetPath] = await Promise.all([ |
| 92 | − realpath(input.cwd), | |
| 93 | − realpath(target.absolutePath), | |
| 92 | + NodeFSP.realpath(input.cwd), | |
| 93 | + NodeFSP.realpath(target.absolutePath), | |
| 94 | 94 | ]); |
| 95 | 95 | const relativeRealPath = path.relative(realWorkspaceRoot, realTargetPath); |
| 96 | 96 | if ( |
| @@ -101,7 +101,7 @@ export const make = Effect.gen(function* () { · 4 unmodified lines | ||
| 101 | 101 | throw new Error("Workspace file path resolves outside the project root."); |
| 102 | 102 | } |
| 103 | 103 | |
| 104 | − const handle = await open(realTargetPath, "r"); | |
| 104 | + const handle = await NodeFSP.open(realTargetPath, "r"); | |
| 105 | 105 | try { |
| 106 | 106 | const stat = await handle.stat(); |
| 107 | 107 | if (!stat.isFile()) { |