Skip to content

Commit 1c15f45

Browse files
Merge pull request #1360 from skaut/dependabot/npm_and_yarn/undici-5.28.5
Bump undici from 5.28.4 to 5.28.5
2 parents 48fab0e + 83a2bc6 commit 1c15f45

File tree

2 files changed

+146
-4
lines changed

2 files changed

+146
-4
lines changed

dist/index.js

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16023,6 +16023,14 @@ const { isUint8Array, isArrayBuffer } = __nccwpck_require__(8253)
1602316023
const { File: UndiciFile } = __nccwpck_require__(3041)
1602416024
const { parseMIMEType, serializeAMimeType } = __nccwpck_require__(4322)
1602516025

16026+
let random
16027+
try {
16028+
const crypto = __nccwpck_require__(7598)
16029+
random = (max) => crypto.randomInt(0, max)
16030+
} catch {
16031+
random = (max) => Math.floor(Math.random(max))
16032+
}
16033+
1602616034
let ReadableStream = globalThis.ReadableStream
1602716035

1602816036
/** @type {globalThis['File']} */
@@ -16108,7 +16116,7 @@ function extractBody (object, keepalive = false) {
1610816116
// Set source to a copy of the bytes held by object.
1610916117
source = new Uint8Array(object.buffer.slice(object.byteOffset, object.byteOffset + object.byteLength))
1611016118
} else if (util.isFormDataLike(object)) {
16111-
const boundary = `----formdata-undici-0${`${Math.floor(Math.random() * 1e11)}`.padStart(11, '0')}`
16119+
const boundary = `----formdata-undici-0${`${random(1e11)}`.padStart(11, '0')}`
1611216120
const prefix = `--${boundary}\r\nContent-Disposition: form-data`
1611316121

1611416122
/*! formdata-polyfill. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> */
@@ -31064,6 +31072,13 @@ module.exports = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("net");
3106431072

3106531073
/***/ }),
3106631074

31075+
/***/ 7598:
31076+
/***/ ((module) => {
31077+
31078+
module.exports = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:crypto");
31079+
31080+
/***/ }),
31081+
3106731082
/***/ 8474:
3106831083
/***/ ((module) => {
3106931084

package-lock.json

Lines changed: 130 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)