MCPcopy Index your code
hub / github.com/di-sukharev/opencommit / getContentLength

Method getContentLength

out/cli.cjs:68823–68832  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

68821 });
68822 Object.defineProperties(this, {
68823 boundary: { writable: false, configurable: false },
68824 contentType: { writable: false, configurable: false },
68825 contentLength: { writable: false, configurable: false },
68826 headers: { writable: false, configurable: false }
68827 });
68828 }
68829 getContentLength() {
68830 let length = 0;
68831 for (const [name, raw] of __classPrivateFieldGet4(this, _FormDataEncoder_form, "f")) {
68832 const value = isFileLike(raw) ? raw : __classPrivateFieldGet4(this, _FormDataEncoder_encoder, "f").encode(normalizeValue_default(raw));
68833 length += __classPrivateFieldGet4(this, _FormDataEncoder_instances, "m", _FormDataEncoder_getFieldHeader).call(this, name, value).byteLength;
68834 length += isFileLike(value) ? value.size : value.byteLength;
68835 length += __classPrivateFieldGet4(this, _FormDataEncoder_CRLF_BYTES_LENGTH, "f");

Callers 3

constructorMethod · 0.80
cli.cjsFile · 0.80
resolveBodyLengthFunction · 0.80

Calls 3

__classPrivateFieldGet4Function · 0.85
isFileLikeFunction · 0.85
encodeMethod · 0.80

Tested by

no test coverage detected