@nextlyhq/storage-s3 0.0.2-alpha.74 → 0.0.2-alpha.75
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.cjs +10 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +10 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -2,7 +2,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
2
2
|
let _aws_sdk_client_s3 = require("@aws-sdk/client-s3");
|
|
3
3
|
let _aws_sdk_lib_storage = require("@aws-sdk/lib-storage");
|
|
4
4
|
let _aws_sdk_s3_request_presigner = require("@aws-sdk/s3-request-presigner");
|
|
5
|
-
// ../nextly/dist/nextly-error-
|
|
5
|
+
// ../nextly/dist/nextly-error-BElDQWyI.mjs
|
|
6
6
|
function isDbError(err) {
|
|
7
7
|
if (!err || typeof err !== "object") return false;
|
|
8
8
|
const obj = err;
|
|
@@ -130,6 +130,8 @@ const NEXTLY_ERROR_STATUS = {
|
|
|
130
130
|
NEXTLY_MIGRATION_SNAPSHOT_MISSING: 404,
|
|
131
131
|
NEXTLY_MIGRATION_RESOLVE_DRIFT: 409,
|
|
132
132
|
NEXTLY_MIGRATION_RESOLVE_PRECONDITION: 409,
|
|
133
|
+
NEXTLY_MIGRATION_HISTORY_REFUSED: 409,
|
|
134
|
+
NEXTLY_SCHEMA_CONVERSION_UNCONFIRMED: 409,
|
|
133
135
|
NEXTLY_UI_SCHEMA_INVALID: 400,
|
|
134
136
|
NEXTLY_SCHEMA_SLUG_COLLISION: 409,
|
|
135
137
|
NEXTLY_SCHEMA_RELATION_TARGET_MISSING: 400,
|
|
@@ -681,10 +683,15 @@ var NextlyError = class NextlyError extends Error {
|
|
|
681
683
|
logContext: opts.logContext
|
|
682
684
|
});
|
|
683
685
|
}
|
|
686
|
+
/**
|
|
687
|
+
* `message` replaces the generic sentence where the caller can name what is
|
|
688
|
+
* already taken without leaking anything, such as a public address and the
|
|
689
|
+
* page holding it.
|
|
690
|
+
*/
|
|
684
691
|
static duplicate(opts) {
|
|
685
692
|
return new NextlyError({
|
|
686
693
|
code: "DUPLICATE",
|
|
687
|
-
publicMessage: "Resource already exists.",
|
|
694
|
+
publicMessage: opts?.message ?? "Resource already exists.",
|
|
688
695
|
logContext: opts?.logContext
|
|
689
696
|
});
|
|
690
697
|
}
|
|
@@ -854,7 +861,7 @@ var NextlyError = class NextlyError extends Error {
|
|
|
854
861
|
return NextlyError.isCode(err, "RATE_LIMITED");
|
|
855
862
|
}
|
|
856
863
|
};
|
|
857
|
-
// ../nextly/dist/validate-external-url-
|
|
864
|
+
// ../nextly/dist/validate-external-url-DNl_UEVd.mjs
|
|
858
865
|
/** Default response body cap: reject anything larger before buffering it all. */
|
|
859
866
|
/**
|
|
860
867
|
* How many bytes a bounded external read may buffer, absent a caller's own cap.
|