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

Function empty

packages/effect/src/http/HttpServerResponse.ts:136–144  ·  view source on GitHub ↗
(
  options?: Options.WithContent | undefined
)

Source from the content-addressed store, hash-verified

134 * @since 4.0.0
135 */
136export const empty = (
137 options?: Options.WithContent | undefined
138): HttpServerResponse =>
139 makeResponse({
140 status: options?.status ?? 204,
141 statusText: options?.statusText,
142 headers: options?.headers ? Headers.fromInput(options.headers) : undefined,
143 cookies: options?.cookies
144 })
145
146/**
147 * Creates a redirect response with a `Location` header.

Callers 1

fromWebFunction · 0.70

Calls 1

makeResponseFunction · 0.70

Tested by

no test coverage detected