MCPcopy Create free account
hub / github.com/tiann/hapi / decodeWsText

Function decodeWsText

hub/src/web/server.ts:45–49  ·  view source on GitHub ↗
(message: string | ArrayBuffer | Uint8Array)

Source from the content-addressed store, hash-verified

43}
44
45function decodeWsText(message: string | ArrayBuffer | Uint8Array): string {
46 if (typeof message === 'string') return message
47 const bytes = message instanceof Uint8Array ? message : new Uint8Array(message)
48 return new TextDecoder().decode(bytes)
49}
50
51function isGeminiSetupFrame(message: string | ArrayBuffer | Uint8Array): boolean {
52 try {

Callers 2

isGeminiSetupFrameFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected