MCPcopy
hub / github.com/mongodb/node-mongodb-native / randomBytes

Function randomBytes

src/utils.ts:1269–1271  ·  view source on GitHub ↗
(size: number)

Source from the content-addressed store, hash-verified

1267}
1268
1269export const randomBytes = (size: number): Promise<Uint8Array> => {
1270 return Promise.resolve(crypto.getRandomValues(new Uint8Array(size)));
1271};
1272
1273/**
1274 * Replicates the events.once helper.

Callers 2

authMethod · 0.90
prepareMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected