Site/Module setup work and auto_format fixes
This commit is contained in:
@@ -46,14 +46,17 @@ class Model_Setup extends ORMOSB {
|
||||
if (! $mo->loaded())
|
||||
throw new Kohana_Exception('Unknown module :name',array(':name'=>$key));
|
||||
|
||||
$mc = $this->module_config ? $this->module_config : array();
|
||||
|
||||
// If $value is NULL, we are a getter
|
||||
if ($value === NULL)
|
||||
return empty($this->module_config[$mo->id]) ? array() : $this->module_config[$mo->id];
|
||||
return empty($mc[$mo->id]) ? array() : $mc[$mo->id];
|
||||
|
||||
// Store new value
|
||||
$this->module_config[$mo->id] = $value;
|
||||
$mc[$mo->id] = $value;
|
||||
$this->module_config = $mc;
|
||||
|
||||
return $value;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -73,7 +76,7 @@ class Model_Setup extends ORMOSB {
|
||||
// Store new value
|
||||
$sc[$key] = $value;
|
||||
|
||||
return $value;
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
Reference in New Issue
Block a user