Skip to content

Commit

Permalink
Merge pull request #614 from SamuelWN/TL
Browse files Browse the repository at this point in the history
Update google.py - Catch TypeError
  • Loading branch information
zyddnys authored May 1, 2024
2 parents 373e889 + ef44710 commit e0e04ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion manga_translator/translators/google.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ async def _request_and_parse_translation(self, query, to_lang, from_lang):
for part in parsed[1][0][0][5]:
try:
translated_parts.append(part[4][1][0])
except IndexError:
except (IndexError, TypeError):
translated_parts.append(part[0])
except IndexError:
translated_parts.append("")
Expand Down

0 comments on commit e0e04ff

Please sign in to comment.