Added Log to Session

This commit is contained in:
Tobias Reich 2014-05-30 16:55:56 +02:00
parent 4e52b1e545
commit b4226d7bdd

View File

@ -31,8 +31,12 @@ class Session extends Module {
$this->plugins(__METHOD__, 0, func_get_args());
# Update
if (!isset($this->settings['version'])||$this->settings['version']!==$version)
if (!Database::update($database, $dbName, @$this->settings['version'])) exit('Error: Updating the database failed!');
if (!isset($this->settings['version'])||$this->settings['version']!==$version) {
if (!Database::update($database, $dbName, @$this->settings['version'])) {
Log::error($database, __METHOD__, __LINE__, 'Updating the database failed');
exit('Error: Updating the database failed!');
}
}
# Return settings
$return['config'] = $this->settings;