Skip to content

⚡️⚡️⚡️ Self-hosted collaborative bookmark manager to collect, read, annotate, and fully preserve what matters, all in one place.

bypass error

daniel31x133565ad3e7c89
diff --git a/lib/api/archiveHandler.ts b/lib/api/archiveHandler.ts
index ce919b3d..60ea7901 100644
--- a/lib/api/archiveHandler.ts
+++ b/lib/api/archiveHandler.ts
@@ -43,7 +43,8 @@ export default async function archiveHandler(link: LinksAndCollectionAndOwner) {
? await validateUrlSize(link.url)
: undefined;
- if (validatedUrl === null) throw "File is too large to be stored.";
+ if (validatedUrl === null)
+ throw "Something went wrong while retrieving the file size.";
const contentType = validatedUrl?.get("content-type");
let linkType = "url";
diff --git a/lib/api/controllers/links/postLink.ts b/lib/api/controllers/links/postLink.ts
index 2877c816..1c82fc2f 100644
--- a/lib/api/controllers/links/postLink.ts
+++ b/lib/api/controllers/links/postLink.ts
@@ -67,12 +67,6 @@ export default async function postLink(
const validatedUrl = link.url ? await validateUrlSize(link.url) : undefined;
- if (validatedUrl === null)
- return {
- response: "Something went wrong while retrieving the file size.",
- status: 400,
- };
-
const contentType = validatedUrl?.get("content-type");
let linkType = "url";
let imageExtension = "png";