From 5e5b80a8ff933eb11832e368bb03742f42f09cae Mon Sep 17 00:00:00 2001 From: Franco <115720207+Francoo86@users.noreply.github.com> Date: Mon, 24 Jun 2024 19:38:45 -0400 Subject: [PATCH] fix api target_lang param not working --- manga_translator/manga_translator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manga_translator/manga_translator.py b/manga_translator/manga_translator.py index 991a7ab7a..b542deea8 100644 --- a/manga_translator/manga_translator.py +++ b/manga_translator/manga_translator.py @@ -1284,7 +1284,7 @@ def format_translate(self, ctx: Context, return_image: bool): return web.json_response({'details': results, 'img': img}) class PostSchema(Schema): - target_language = fields.Str(required=False, validate=lambda a: a.upper() in VALID_LANGUAGES) + target_lang = fields.Str(required=False, validate=lambda a: a.upper() in VALID_LANGUAGES) detector = fields.Str(required=False, validate=lambda a: a.lower() in DETECTORS) ocr = fields.Str(required=False, validate=lambda a: a.lower() in OCRS) inpainter = fields.Str(required=False, validate=lambda a: a.lower() in INPAINTERS)