MCPcopy Index your code
hub / github.com/nodejs/node / assertEncoding

Function assertEncoding

lib/internal/fs/utils.js:161–166  ·  view source on GitHub ↗
(encoding)

Source from the content-addressed store, hash-verified

159}
160
161function assertEncoding(encoding) {
162 if (encoding && !Buffer.isEncoding(encoding)) {
163 const reason = 'is invalid encoding';
164 throw new ERR_INVALID_ARG_VALUE('encoding', encoding, reason);
165 }
166}
167
168class Dirent {
169 constructor(name, type, path) {

Callers 3

readFileSyncFunction · 0.85
readFileFunction · 0.85
getOptionsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…