Commit 827daf7c authored by Ad Schellevis's avatar Ad Schellevis

sync master

parent d2fe8718
...@@ -364,7 +364,7 @@ class Config extends Singleton ...@@ -364,7 +364,7 @@ class Config extends Singleton
public function restoreBackup($filename) public function restoreBackup($filename)
{ {
if ($this->statusIsValid) { if ($this->isValid()) {
// if current config is valid, // if current config is valid,
$simplexml = $this->simplexml; $simplexml = $this->simplexml;
try { try {
...@@ -377,6 +377,7 @@ class Config extends Singleton ...@@ -377,6 +377,7 @@ class Config extends Singleton
$this->simplexml = $simplexml; $this->simplexml = $simplexml;
$this->statusIsValid = true; $this->statusIsValid = true;
$this->save(null, true); $this->save(null, true);
return false;
} }
} else { } else {
// we don't have a valid config loaded, just copy and load the requested one // we don't have a valid config loaded, just copy and load the requested one
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment