mirror of
https://github.com/anomalyco/opencode.git
synced 2026-08-30 05:01:53 +00:00
refactor: reuse undefined effect (#44010)
This commit is contained in:
parent
667c274c7f
commit
c4eeefe0f1
28 changed files with 41 additions and 42 deletions
|
|
@ -1426,7 +1426,7 @@ export function write(
|
|||
output.files,
|
||||
(file) =>
|
||||
fs.exists(join(directory, file.path)).pipe(
|
||||
Effect.flatMap((exists) => (exists ? fs.stat(join(directory, file.path)) : Effect.succeed(undefined))),
|
||||
Effect.flatMap((exists) => (exists ? fs.stat(join(directory, file.path)) : Effect.undefined)),
|
||||
Effect.flatMap((info) =>
|
||||
info?.type === "SymbolicLink"
|
||||
? new GenerationError({ reason: `Unsafe output path: ${file.path}` })
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue