From 8a45d25912f806dacf19d7514422a53e6dd103db 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 211aa3931e..b5eece0f6e 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 dfaacf9e50..683ffc6223 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: {