@nextlyhq/storage-uploadthing 0.0.2-alpha.65 → 0.0.2-alpha.66
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/{chunk-W3CIFTIH.mjs → chunk-CNPHOD4B.mjs} +12 -5
- package/dist/chunk-CNPHOD4B.mjs.map +1 -0
- package/dist/{dist-4FMXMKHX.mjs → dist-QOPNSZNF.mjs} +85 -90
- package/dist/dist-QOPNSZNF.mjs.map +1 -0
- package/dist/index.cjs +33 -26
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/local-plugin-2MPAVX5S-Q66ISMJN.mjs +4 -0
- package/dist/{local-plugin-X4OF5FWU-MLZIPEH2.mjs.map → local-plugin-2MPAVX5S-Q66ISMJN.mjs.map} +1 -1
- package/package.json +4 -4
- package/dist/chunk-W3CIFTIH.mjs.map +0 -1
- package/dist/dist-4FMXMKHX.mjs.map +0 -1
- package/dist/local-plugin-X4OF5FWU-MLZIPEH2.mjs +0 -4
package/dist/index.cjs
CHANGED
|
@@ -9,7 +9,7 @@ var __esm = (fn, res) => function __init() {
|
|
|
9
9
|
return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
|
|
10
10
|
};
|
|
11
11
|
|
|
12
|
-
// ../nextly/dist/chunk-
|
|
12
|
+
// ../nextly/dist/chunk-IAZJNA2U.mjs
|
|
13
13
|
function isDbError(err) {
|
|
14
14
|
if (!err || typeof err !== "object") return false;
|
|
15
15
|
const obj = err;
|
|
@@ -22,8 +22,8 @@ function hasBrand(value) {
|
|
|
22
22
|
return value[NEXTLY_ERROR_BRAND] === true;
|
|
23
23
|
}
|
|
24
24
|
var NEXTLY_ERROR_STATUS, CANONICAL_CODE_FOR_STATUS, LEGACY_UNPROCESSABLE_STATUS, DB_ERROR_MAPPING, NEXTLY_ERROR_BRAND, NextlyError;
|
|
25
|
-
var
|
|
26
|
-
"../nextly/dist/chunk-
|
|
25
|
+
var init_chunk_IAZJNA2U = __esm({
|
|
26
|
+
"../nextly/dist/chunk-IAZJNA2U.mjs"() {
|
|
27
27
|
NEXTLY_ERROR_STATUS = {
|
|
28
28
|
VALIDATION_ERROR: 400,
|
|
29
29
|
INVALID_INPUT: 400,
|
|
@@ -121,6 +121,13 @@ var init_chunk_HJ5IQPOY = __esm({
|
|
|
121
121
|
// Plugin platform (P4) — contributes.routes collection (D25).
|
|
122
122
|
NEXTLY_ROUTE_COLLISION: 409,
|
|
123
123
|
NEXTLY_ROUTE_INVALID_PATH: 400,
|
|
124
|
+
// A root-mounted route declared where the request pipeline never reaches the
|
|
125
|
+
// root pass. 400 like an invalid path and not 409: nothing else claims the
|
|
126
|
+
// address, the declaration simply cannot be served from there.
|
|
127
|
+
NEXTLY_ROUTE_UNREACHABLE_ROOT: 400,
|
|
128
|
+
// A `mount` outside the declared union, which only an untyped caller can
|
|
129
|
+
// produce. 400 for the same reason: the declaration itself is unserveable.
|
|
130
|
+
NEXTLY_ROUTE_INVALID_MOUNT: 400,
|
|
124
131
|
// An email transport whose library is an optional peer dependency the host
|
|
125
132
|
// has not installed. 503 rather than 500: the request is not malformed and
|
|
126
133
|
// nothing is broken, the install simply cannot carry it out yet, and the
|
|
@@ -457,11 +464,11 @@ var init_chunk_HJ5IQPOY = __esm({
|
|
|
457
464
|
}
|
|
458
465
|
});
|
|
459
466
|
|
|
460
|
-
// ../nextly/dist/chunk-
|
|
467
|
+
// ../nextly/dist/chunk-T3OVIJZM.mjs
|
|
461
468
|
var StorageReadTooLargeError;
|
|
462
|
-
var
|
|
463
|
-
"../nextly/dist/chunk-
|
|
464
|
-
|
|
469
|
+
var init_chunk_T3OVIJZM = __esm({
|
|
470
|
+
"../nextly/dist/chunk-T3OVIJZM.mjs"() {
|
|
471
|
+
init_chunk_IAZJNA2U();
|
|
465
472
|
StorageReadTooLargeError = class extends NextlyError {
|
|
466
473
|
constructor(path, maxBytes, size) {
|
|
467
474
|
super({
|
|
@@ -481,7 +488,7 @@ var init_chunk_W77AQUUQ = __esm({
|
|
|
481
488
|
}
|
|
482
489
|
});
|
|
483
490
|
|
|
484
|
-
// ../nextly/dist/chunk-
|
|
491
|
+
// ../nextly/dist/chunk-YGE6AGZG.mjs
|
|
485
492
|
async function validateExternalUrl(rawUrl, options = {}) {
|
|
486
493
|
let parsed;
|
|
487
494
|
try {
|
|
@@ -930,10 +937,10 @@ async function withDeadline(work, signal) {
|
|
|
930
937
|
]);
|
|
931
938
|
}
|
|
932
939
|
var IPV4_RE, PRIVATE_IPV4_CIDRS, CLOUD_METADATA_HOSTS, ExternalUrlError, DEFAULT_MAX_RESPONSE_BYTES, DEFAULT_TIMEOUT_MS, SafeFetchError, DEFAULT_READ_TIMEOUT_MS, DEFAULT_READ_MAX_BYTES;
|
|
933
|
-
var
|
|
934
|
-
"../nextly/dist/chunk-
|
|
935
|
-
|
|
936
|
-
|
|
940
|
+
var init_chunk_YGE6AGZG = __esm({
|
|
941
|
+
"../nextly/dist/chunk-YGE6AGZG.mjs"() {
|
|
942
|
+
init_chunk_T3OVIJZM();
|
|
943
|
+
init_chunk_IAZJNA2U();
|
|
937
944
|
IPV4_RE = /^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/;
|
|
938
945
|
PRIVATE_IPV4_CIDRS = [
|
|
939
946
|
"0.0.0.0/8",
|
|
@@ -1002,12 +1009,12 @@ var init_chunk_C2VHLQKK = __esm({
|
|
|
1002
1009
|
}
|
|
1003
1010
|
});
|
|
1004
1011
|
|
|
1005
|
-
// ../nextly/dist/chunk-
|
|
1012
|
+
// ../nextly/dist/chunk-BD2ROWEF.mjs
|
|
1006
1013
|
var BaseStorageAdapter;
|
|
1007
|
-
var
|
|
1008
|
-
"../nextly/dist/chunk-
|
|
1009
|
-
|
|
1010
|
-
|
|
1014
|
+
var init_chunk_BD2ROWEF = __esm({
|
|
1015
|
+
"../nextly/dist/chunk-BD2ROWEF.mjs"() {
|
|
1016
|
+
init_chunk_YGE6AGZG();
|
|
1017
|
+
init_chunk_T3OVIJZM();
|
|
1011
1018
|
BaseStorageAdapter = class {
|
|
1012
1019
|
/**
|
|
1013
1020
|
* Get adapter info including capabilities.
|
|
@@ -1092,21 +1099,21 @@ var init_chunk_7P6ASYW6 = __esm({
|
|
|
1092
1099
|
}
|
|
1093
1100
|
});
|
|
1094
1101
|
|
|
1095
|
-
// ../nextly/dist/chunk-
|
|
1096
|
-
|
|
1102
|
+
// ../nextly/dist/chunk-S2YG6ODY.mjs
|
|
1103
|
+
init_chunk_BD2ROWEF();
|
|
1097
1104
|
module$1.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('index.cjs', document.baseURI).href)));
|
|
1098
1105
|
|
|
1099
1106
|
// ../nextly/dist/storage/index.mjs
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1107
|
+
init_chunk_BD2ROWEF();
|
|
1108
|
+
init_chunk_YGE6AGZG();
|
|
1109
|
+
init_chunk_T3OVIJZM();
|
|
1110
|
+
init_chunk_IAZJNA2U();
|
|
1104
1111
|
init_chunk_7P6ASYW6();
|
|
1105
1112
|
|
|
1106
1113
|
// ../nextly/dist/storage/fetch-stored-bytes.mjs
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1114
|
+
init_chunk_YGE6AGZG();
|
|
1115
|
+
init_chunk_T3OVIJZM();
|
|
1116
|
+
init_chunk_IAZJNA2U();
|
|
1110
1117
|
init_chunk_7P6ASYW6();
|
|
1111
1118
|
var UploadthingStorageAdapter = class extends BaseStorageAdapter {
|
|
1112
1119
|
utapi;
|