SimaDovakin
commited on
Temporary fix the problem with translation Russian into Ukrainian (#89)
Browse files
deep_translator/google_trans.py
CHANGED
|
@@ -89,6 +89,10 @@ class GoogleTranslator(BaseTranslator):
|
|
| 89 |
|
| 90 |
if self.payload_key:
|
| 91 |
self._url_params[self.payload_key] = text
|
|
|
|
|
|
|
|
|
|
|
|
|
| 92 |
|
| 93 |
response = requests.get(self.__base_url,
|
| 94 |
params=self._url_params,
|
|
|
|
| 89 |
|
| 90 |
if self.payload_key:
|
| 91 |
self._url_params[self.payload_key] = text
|
| 92 |
+
|
| 93 |
+
# temporary fix the problem with translation Russian into Ukrainian
|
| 94 |
+
if self._source == 'ru' and self._target == 'uk':
|
| 95 |
+
self._url_params['tl'] = 'uk'
|
| 96 |
|
| 97 |
response = requests.get(self.__base_url,
|
| 98 |
params=self._url_params,
|