diff --git a/_class/locale.class.php b/_class/locale.class.php index 345343b..e37c926 100644 --- a/_class/locale.class.php +++ b/_class/locale.class.php @@ -65,7 +65,9 @@ static public function load($code) $handle = fopen($file, 'r'); while (!feof($handle)) { $line = fgetcsv($handle); - if (count($line)!=2) continue; + if (!$line || count($line) != 2) { + continue; + } self::$_list[trim($line[0])] = trim($line[1]); } fclose($handle); @@ -93,4 +95,4 @@ static public function get($key, $default='######') { return (isset(self::$_list[$key]) ? self::$_list[$key] : $default); } -} \ No newline at end of file +}