MCPcopy
hub / github.com/prisma/prisma / withCors

Function withCors

packages/cli/src/Studio.ts:690–699  ·  view source on GitHub ↗
(response: Response)

Source from the content-addressed store, hash-verified

688}
689
690function withCors(response: Response): Response {
691 const headers = new Headers(response.headers)
692 headers.set('Access-Control-Allow-Origin', '*')
693
694 return new Response(response.body, {
695 headers,
696 status: response.status,
697 statusText: response.statusText,
698 })
699}

Callers 4

serveStudioAssetFunction · 0.85
jsonResponseFunction · 0.85
emptyResponseFunction · 0.85
textResponseFunction · 0.85

Calls 1

setMethod · 0.80

Tested by

no test coverage detected