From 54ea4f7f8f164c61ac3d746e9ac985861d02b7fc Mon Sep 17 00:00:00 2001 From: Markov Andrei <38224264+markovav-official@users.noreply.github.com> Date: Sun, 30 May 2021 12:11:00 +0500 Subject: [PATCH] Fix API limits --- translate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/translate.py b/translate.py index d45f3f7..ea8054a 100644 --- a/translate.py +++ b/translate.py @@ -62,7 +62,7 @@ def translate_threaded(self, mode, text): paragraph_res = [] chunks = [] for word in paragraph.split(): - if len(chunks) == 0 or len(chunks[-1]) > 900: + if len(chunks) == 0 or len(chunks[-1]) > 800: chunks.append(word) else: chunks[-1] += ' ' + word