Misc many fixes

This commit is contained in:
Deon George
2011-09-17 20:45:08 +10:00
parent 52074d239b
commit 7180e01dcf
18 changed files with 162 additions and 55 deletions

View File

@@ -4,20 +4,10 @@ class Config extends lnApp_Config {
/**
* Find a list of all database enabled modules
*
* @uses cache
* Our available modules are defined in the DB (along with method
* security).
*/
public static function appmodules() {
$cacheable = TRUE;
if (array_key_exists('cache',Kohana::modules())) {
$cache = Cache::instance(static::cachetype());
if ($cacheable AND $cache->get('modules'))
return $cache->get('modules');
} else
$cache = '';
$modules = array();
$module_table = 'module';
@@ -28,9 +18,6 @@ class Config extends lnApp_Config {
$modules[$o->name] = MODPATH.$o->name;
}
if ($cache)
$cache->set('modules',$modules);
return $modules;
}
}