From 5ae8ff07592b6f1c18906eb17c4ebd3dddf8cead Mon Sep 17 00:00:00 2001 From: Bruce Berrios <58147810+Bruception@users.noreply.github.com> Date: Sun, 6 Mar 2022 07:33:53 -0500 Subject: [PATCH] Remove quote languages check (#2645) --- backend/api/routes/quotes.ts | 6 +---- backend/constants/quote-languages.ts | 37 ---------------------------- 2 files changed, 1 insertion(+), 42 deletions(-) delete mode 100644 backend/constants/quote-languages.ts diff --git a/backend/api/routes/quotes.ts b/backend/api/routes/quotes.ts index 89ee10bd8..5fe0957d9 100644 --- a/backend/api/routes/quotes.ts +++ b/backend/api/routes/quotes.ts @@ -9,7 +9,6 @@ import { validateConfiguration, validateRequest, } from "../../middlewares/api-utils"; -import SUPPORTED_QUOTE_LANGUAGES from "../../constants/quote-languages"; const quotesRouter = Router(); @@ -119,10 +118,7 @@ quotesRouter.post( validateRequest({ body: { quoteId: joi.string().required(), - quoteLanguage: joi - .string() - .valid(...SUPPORTED_QUOTE_LANGUAGES) - .required(), + quoteLanguage: joi.string().required(), reason: joi .string() .valid( diff --git a/backend/constants/quote-languages.ts b/backend/constants/quote-languages.ts deleted file mode 100644 index a58356ae5..000000000 --- a/backend/constants/quote-languages.ts +++ /dev/null @@ -1,37 +0,0 @@ -const SUPPORTED_QUOTE_LANGUAGES = [ - "albanian", - "arabic", - "code_c++", - "code_c", - "code_java", - "code_javascript", - "code_python", - "code_rust", - "czech", - "danish", - "dutch", - "english", - "filipino", - "french", - "german", - "hindi", - "icelandic", - "indonesian", - "irish", - "italian", - "lithuanian", - "malagasy", - "polish", - "portuguese", - "russian", - "serbian", - "slovak", - "spanish", - "swedish", - "thai", - "toki_pona", - "turkish", - "vietnamese", -]; - -export default SUPPORTED_QUOTE_LANGUAGES;