From 8427f86275b259f99203e64d70cd2edf87f6922c Mon Sep 17 00:00:00 2001 From: Piero Toffanin Date: Wed, 8 Nov 2023 21:58:59 -0500 Subject: [PATCH] Minor refactor --- libretranslate/app.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libretranslate/app.py b/libretranslate/app.py index d4e4354..8c34dda 100644 --- a/libretranslate/app.py +++ b/libretranslate/app.py @@ -578,7 +578,7 @@ def create_app(args): try: if batch: results = [] - for _idx, text in enumerate(q): + for text in q: translator = src_lang.get_translation(tgt_lang) if translator is None: abort(400, description=_("%(tname)s (%(tcode)s) is not available as a target language from %(sname)s (%(scode)s)", tname=_lazy(tgt_lang.name), tcode=tgt_lang.code, sname=_lazy(src_lang.name), scode=src_lang.code))