Fix registration

This commit is contained in:
Giuseppe Criscione 2023-12-03 11:05:48 +01:00
parent af5cf6103d
commit daf48f40eb

View File

@ -23,7 +23,6 @@ class RegisterController extends AbstractController
return $this->redirectToReferer();
}
$request->session()->regenerate(false);
$csrfToken->generate();
switch ($request->method()) {
@ -53,6 +52,7 @@ class RegisterController extends AbstractController
Yaml::encodeToFile($userData, FileSystem::joinPaths($this->config->get('system.panel.paths.accounts'), $data->get('username') . '.yaml'));
$request->session()->regenerate();
$request->session()->set('FORMWORK_USERNAME', $data->get('username'));
$accessLog = new Log(FileSystem::joinPaths($this->config->get('system.panel.paths.logs'), 'access.json'));