Minor internal fixes

This commit is contained in:
Deon George
2014-10-04 00:35:26 +10:00
parent a7ed6672e1
commit f679bf9c06
9 changed files with 44 additions and 28 deletions

View File

@@ -51,12 +51,11 @@ abstract class lnApp_Site {
$k = sprintf('%s_%s',strtolower($k),strtoupper($v));
}
if ($x=ORM::factory('Language',array('iso'=>$k)))
if ($x=ORM::factory('Language',array('iso'=>$k)) AND $x->loaded())
return $x;
}
// @todo Return Default Language
return Kohana::$config->load('config')->language;
return ORM::factory('Language',array('iso'=>Kohana::$config->load('config')->language));
}
/**