Fix session cookie path for login

This commit is contained in:
Matias Griese
2015-01-20 14:28:16 +02:00
parent 845d8d9479
commit f2dbf9181d

View File

@@ -94,6 +94,7 @@ class AdminPlugin extends Plugin
if (substr($this->uri->route(), 0, strlen($this->base)) == $this->base) {
// Change login behavior.
$this->config->set('plugins.login', $this->config->get('plugins.admin.login'));
$this->config->set('plugins.login.session.path', $this->uri->rootUrl(false) . $this->base);
$this->active = true;
}
@@ -278,9 +279,6 @@ class AdminPlugin extends Plugin
'onTask.GPM' => ['onTaskGPM', 0]
]);
// Change login behavior.
$this->config->set('plugins.login', $this->config->get('plugins.admin.login'));
// Decide admin template and route.
$path = trim(substr($this->uri->route(), strlen($this->base)), '/');
$this->template = 'dashboard';