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

Function toBuffers

packages/platform/node-shared/src/NodeSocket.ts:58–59  ·  view source on GitHub ↗
(input: string | Uint8Array | ReadonlyArray<string | Uint8Array>)

Source from the content-addressed store, hash-verified

56}
57
58const toBuffers = (input: string | Uint8Array | ReadonlyArray<string | Uint8Array>): Array<Buffer> =>
59 Arr.map(Arr.ensure(input), (value) => Buffer.from(value))
60
61const closeSocket = (conn: Net.Socket, isOpen: boolean) => {
62 if (conn.closed !== false) return

Callers 1

upgradeFunction · 0.85

Calls 3

fromMethod · 0.80
mapMethod · 0.45
ensureMethod · 0.45

Tested by

no test coverage detected