compilemessages: Weblate's Language-Team uses <>.

(cherry picked from commit 4c2cf4dca8)
This commit is contained in:
Alex Vandiver
2025-07-18 04:33:52 +00:00
parent e630281275
commit cb8dc451a8

View File

@@ -68,7 +68,7 @@ class Command(compilemessages.Command):
def get_name_from_po_file(self, po_filename: str, locale: str) -> str:
try:
team = polib.pofile(po_filename).metadata["Language-Team"]
return team[: team.rindex(" (")]
return team[: team.rindex(" <")]
except (KeyError, ValueError):
raise Exception(f"Unknown language {locale}")