From 6906cb3a49645f96e0579318bb8151f58956e8a2 Mon Sep 17 00:00:00 2001 From: Elijah Perrault Date: Mon, 17 Jan 2011 00:01:15 -0700 Subject: [PATCH] Use English if the language is not found. --- src/Parser/Lang.pm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Parser/Lang.pm b/src/Parser/Lang.pm index 94088d1..161f6b2 100644 --- a/src/Parser/Lang.pm +++ b/src/Parser/Lang.pm @@ -6,6 +6,7 @@ use warnings; # Language file parser. package Parser::Lang; +use API::Log qw(dbug alog); # Parser. @@ -15,7 +16,10 @@ sub parse # Check that the language file exists. unless (-e "$Auto::Bin/../lang/$lang.alf") { - return 0; + # Otherwise, use English. + dbug "Language '$lang' not found. Using English."; + alog "Language '$lang' not found. Using English."; + $lang = "en"; } # Open, read and close the file.