MCPcopy
hub / github.com/directus/directus / bufferMessage

Function bufferMessage

api/src/websocket/utils/wait-for-message.test.ts:5–7  ·  view source on GitHub ↗
(msg: any)

Source from the content-addressed store, hash-verified

3import { waitForAnyMessage, waitForMessageType } from './wait-for-message.js';
4
5function bufferMessage(msg: any): RawData {
6 return Buffer.from(JSON.stringify(msg));
7}
8
9function mockClient(handler: (callback: (event: RawData) => void) => void) {
10 return {

Callers 1

Calls 1

fromMethod · 0.80

Tested by

no test coverage detected