Localize state names in js-helper

This commit is contained in:
Richard Schreiber
2025-12-22 10:09:49 +01:00
parent fc4ce102b6
commit b88e49311a
+1 -1
View File
@@ -76,7 +76,7 @@ def _info(cc):
statelist = [s for s in pycountry.subdivisions.get(country_code=cc) if s.type in types]
return {
'data': [
{'name': s.name, 'code': s.code[3:]}
{'name': gettext(s.name), 'code': s.code[3:]}
for s in sorted(statelist, key=lambda s: s.name)
],
**info,