From 5e7e5e7da8fdeb8f4c53ef79233891a381fecac3 Mon Sep 17 00:00:00 2001 From: ThatOneCalculator Date: Thu, 22 Jun 2023 16:53:56 -0700 Subject: [PATCH] fix: :pencil2: typo in API docs + errors Co-authored-by: naskya --- packages/backend/src/remote/activitypub/models/image.ts | 4 ++-- packages/backend/src/server/api/openapi/gen-spec.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/backend/src/remote/activitypub/models/image.ts b/packages/backend/src/remote/activitypub/models/image.ts index 211aa3931..b5eece0f6 100644 --- a/packages/backend/src/remote/activitypub/models/image.ts +++ b/packages/backend/src/remote/activitypub/models/image.ts @@ -26,11 +26,11 @@ export async function createImage( const image = (await new Resolver().resolve(value)) as any; if (image.url == null) { - throw new Error("invalid image: url not privided"); + throw new Error("Invalid image, URL not provided"); } if (!image.url.startsWith("https://") && !image.url.startsWith("http://")) { - throw new Error("invalid image: unexpected shcema of url: " + image.url); + throw new Error(`Invalid image, unexpected schema: ${image.url}`); } logger.info(`Creating the Image: ${image.url}`); diff --git a/packages/backend/src/server/api/openapi/gen-spec.ts b/packages/backend/src/server/api/openapi/gen-spec.ts index dfaacf9e5..683ffc622 100644 --- a/packages/backend/src/server/api/openapi/gen-spec.ts +++ b/packages/backend/src/server/api/openapi/gen-spec.ts @@ -182,7 +182,7 @@ export function genOpenapiSpec() { ...(endpoint.meta.limit ? { "429": { - description: "To many requests", + description: "Too many requests", content: { "application/json": { schema: {