[PATCH] Use a slightly different method to get supported languages (#858801, tagoh).

Chris Lumens clumens at redhat.com
Wed Oct 24 19:45:31 UTC 2012


---
 pyanaconda/localization.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/pyanaconda/localization.py b/pyanaconda/localization.py
index 47f4e01..d7c332c 100644
--- a/pyanaconda/localization.py
+++ b/pyanaconda/localization.py
@@ -154,8 +154,8 @@ def get_available_translations(domain=None, localedir=None):
     domain = domain or gettext._current_domain
     localedir = localedir or gettext._default_localedir
 
-    langdict = babel.Locale('en', 'US').languages
-    messagefiles = gettext.find(domain, localedir, langdict.keys(), all=True)
+    langdict = babel.localedata.list()
+    messagefiles = gettext.find(domain, localedir, langdict, all=True)
     languages = [path.split(os.path.sep)[-3] for path in messagefiles]
 
     # usually there are no message files for en
-- 
1.7.11.2



More information about the anaconda-patches mailing list