MCPcopy Create free account
hub / github.com/BrainJS/brain.js / decodeChunk

Function decodeChunk

browser.js:25223–25228  ·  view source on GitHub ↗
(state, chunk, encoding)

Source from the content-addressed store, hash-verified

25221};
25222
25223function decodeChunk(state, chunk, encoding) {
25224 if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') {
25225 chunk = Buffer.from(chunk, encoding);
25226 }
25227 return chunk;
25228}
25229
25230Object.defineProperty(Writable.prototype, 'writableHighWaterMark', {
25231 // making it explicit this property is not enumerable

Callers 1

writeOrBufferFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected