File tree 1 file changed +16
-1
lines changed 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -15684,6 +15684,14 @@ const { isUint8Array, isArrayBuffer } = __nccwpck_require__(8253)
15684
15684
const { File: UndiciFile } = __nccwpck_require__(3041)
15685
15685
const { parseMIMEType, serializeAMimeType } = __nccwpck_require__(4322)
15686
15686
15687
+ let random
15688
+ try {
15689
+ const crypto = __nccwpck_require__(7598)
15690
+ random = (max) => crypto.randomInt(0, max)
15691
+ } catch {
15692
+ random = (max) => Math.floor(Math.random(max))
15693
+ }
15694
+
15687
15695
let ReadableStream = globalThis.ReadableStream
15688
15696
15689
15697
/** @type {globalThis['File']} */
@@ -15769,7 +15777,7 @@ function extractBody (object, keepalive = false) {
15769
15777
// Set source to a copy of the bytes held by object.
15770
15778
source = new Uint8Array(object.buffer.slice(object.byteOffset, object.byteOffset + object.byteLength))
15771
15779
} else if (util.isFormDataLike(object)) {
15772
- const boundary = `----formdata-undici-0${`${Math.floor(Math. random() * 1e11)}`.padStart(11, '0')}`
15780
+ const boundary = `----formdata-undici-0${`${random(1e11)}`.padStart(11, '0')}`
15773
15781
const prefix = `--${boundary}\r\nContent-Disposition: form-data`
15774
15782
15775
15783
/*! formdata-polyfill. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> */
@@ -30741,6 +30749,13 @@ module.exports = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:buffer"
30741
30749
30742
30750
/***/ }),
30743
30751
30752
+ /***/ 7598:
30753
+ /***/ ((module) => {
30754
+
30755
+ module.exports = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:crypto");
30756
+
30757
+ /***/ }),
30758
+
30744
30759
/***/ 8474:
30745
30760
/***/ ((module) => {
30746
30761
You can’t perform that action at this time.
0 commit comments