MCPcopy
hub / github.com/Innei/Shiro / send

Method send

src/lib/edge-function.server.ts:30–40  ·  view source on GitHub ↗
(data: any)

Source from the content-addressed store, hash-verified

28 }
29
30 send(data: any) {
31 // if (data instanceof Stream) {
32 // return
33 // }
34
35 if (typeof data === 'object' || data === undefined) {
36 return this.json(data)
37 }
38
39 return new Response(data, this.makeResponseOptions())
40 }
41
42 text(text: string) {
43 return new Response(text, this.makeResponseOptions())

Callers 4

factoryFunction · 0.80
uploadToS3Function · 0.80
GETFunction · 0.80
POSTFunction · 0.80

Calls 2

jsonMethod · 0.95
makeResponseOptionsMethod · 0.95

Tested by

no test coverage detected