@replayio-app-building/netlify-recorder 0.29.0 → 0.30.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +4 -7
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -665,8 +665,8 @@ async function createRequestRecording(blobUrlOrData, handlerPath, requestInfo) {
|
|
|
665
665
|
const g = globalThis;
|
|
666
666
|
if (typeof g.Blob === "undefined") {
|
|
667
667
|
try {
|
|
668
|
-
const { Blob } = __require("buffer");
|
|
669
|
-
g.Blob =
|
|
668
|
+
const { Blob: Blob2 } = __require("buffer");
|
|
669
|
+
g.Blob = Blob2;
|
|
670
670
|
} catch {
|
|
671
671
|
}
|
|
672
672
|
}
|
|
@@ -1064,11 +1064,8 @@ async function uploadBlobData(blobData, requestId) {
|
|
|
1064
1064
|
);
|
|
1065
1065
|
}
|
|
1066
1066
|
const utapi = new UTApi({ token });
|
|
1067
|
-
const
|
|
1068
|
-
|
|
1069
|
-
`blob-${requestId}.json`,
|
|
1070
|
-
{ type: "application/json" }
|
|
1071
|
-
);
|
|
1067
|
+
const blob = new Blob([blobData], { type: "application/json" });
|
|
1068
|
+
const file = Object.assign(blob, { name: `blob-${requestId}.json` });
|
|
1072
1069
|
const result = await utapi.uploadFiles(file);
|
|
1073
1070
|
if (result.error || !result.data?.ufsUrl) {
|
|
1074
1071
|
throw new Error(
|