Skip to content

Commit

Permalink
Merge pull request #396 from xxyzz/zh
Browse files Browse the repository at this point in the history
Fix None type WikiNode error in Chinese translation extractor
  • Loading branch information
xxyzz authored Nov 9, 2023
2 parents 3a26380 + 2fff3e1 commit 606cebf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/wiktextract/extractor/zh/translation.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def extract_translation(
template_name = child.template_name.lower()
if (
template_name in {"trans-top", "翻譯-頂", "trans-top-also"}
and len(child.template_parameters) > 0
and 1 in child.template_parameters
):
sense_text = clean_node(
wxr, None, child.template_parameters.get(1)
Expand Down

0 comments on commit 606cebf

Please sign in to comment.