X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=application%2FUpdater.php;h=b6cbc56c4b2834a2c05b5cc7a7a4b554add554fa;hb=03542572665bae57705a2f57b0737ed43f4f1415;hp=b8940e4126261c04fa323241874d89e5f6fd4110;hpb=278d9ee2836df7d805845077f26f8cecd16f0f4f;p=github%2Fshaarli%2FShaarli.git diff --git a/application/Updater.php b/application/Updater.php index b8940e41..b6cbc56c 100644 --- a/application/Updater.php +++ b/application/Updater.php @@ -114,8 +114,8 @@ class Updater */ public function updateMethodMergeDeprecatedConfigFile() { - if (is_file($this->conf->get('path.data_dir') . '/options.php')) { - include $this->conf->get('path.data_dir') . '/options.php'; + if (is_file($this->conf->get('resource.data_dir') . '/options.php')) { + include $this->conf->get('resource.data_dir') . '/options.php'; // Load GLOBALS into config $allowedKeys = array_merge(ConfigPhp::$ROOT_KEYS); @@ -126,7 +126,7 @@ class Updater } } $this->conf->write($this->isLoggedIn); - unlink($this->conf->get('path.data_dir').'/options.php'); + unlink($this->conf->get('resource.data_dir').'/options.php'); } return true; @@ -143,7 +143,7 @@ class Updater $link['tags'] = implode(' ', array_unique(LinkFilter::tagsStrToArray($link['tags'], true))); $this->linkDB[$link['linkdate']] = $link; } - $this->linkDB->savedb($this->conf->get('path.page_cache')); + $this->linkDB->savedb($this->conf->get('resource.page_cache')); return true; } @@ -198,16 +198,16 @@ class Updater * Escape settings which have been manually escaped in every request in previous versions: * - general.title * - general.header_link - * - extras.redirector + * - redirector.url * * @return bool true if the update is successful, false otherwise. */ - public function escapeUnescapedConfig() + public function updateMethodEscapeUnescapedConfig() { try { $this->conf->set('general.title', escape($this->conf->get('general.title'))); $this->conf->set('general.header_link', escape($this->conf->get('general.header_link'))); - $this->conf->set('extras.redirector', escape($this->conf->get('extras.redirector'))); + $this->conf->set('redirector.url', escape($this->conf->get('redirector.url'))); $this->conf->write($this->isLoggedIn); } catch (Exception $e) { error_log($e->getMessage());