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

Function makeFilterIssue

packages/effect/src/SchemaIssue.ts:793–808  ·  view source on GitHub ↗
(
  entry: Schema.FilterIssue,
  input?: unknown,
  options?: SchemaAST.ParseOptions
)

Source from the content-addressed store, hash-verified

791}
792
793function makeFilterIssue(
794 entry: Schema.FilterIssue,
795 input?: unknown,
796 options?: SchemaAST.ParseOptions
797): Issue {
798 if (isIssue(entry)) {
799 return entry
800 }
801 if (typeof entry === "string") {
802 return new InvalidValue({ message: entry }, input, options)
803 }
804 const inner = typeof entry.issue === "string"
805 ? new InvalidValue({ message: entry.issue }, input, options)
806 : entry.issue
807 return new Pointer(entry.path, inner)
808}
809
810/** @internal */
811export function makeSingle(

Callers 2

makeSingleFunction · 0.85
normalizeFilterOutputFunction · 0.85

Calls 1

isIssueFunction · 0.85

Tested by

no test coverage detected