MCPcopy Create free account
hub / github.com/Effect-TS/effect / markDefect

Function markDefect

packages/effect/src/ui/Query.ts:6021–6027  ·  view source on GitHub ↗
(
    entry: Entry,
    cause: Cause.Cause<any>
  )

Source from the content-addressed store, hash-verified

6019 }
6020 /** A fetcher's defect is never stored: the previous state stays, marked stale, so a remount fetches fresh. */
6021 const markDefect = (
6022 entry: Entry,
6023 cause: Cause.Cause<any>
6024 ): Cause.Cause<never> => {
6025 if (entry.result !== undefined) entry.invalidated = true
6026 return diesOnly(cause)
6027 }
6028 /** What ends every fetch, after its result is in: the defect and the emission, then the timers. */
6029 const afterFetch = (
6030 entry: Entry,

Callers 1

onFetchExitFunction · 0.85

Calls 1

diesOnlyFunction · 0.85

Tested by

no test coverage detected