mirror of
https://github.com/nextcloud/all-in-one.git
synced 2025-12-20 14:36:52 +00:00
rework session deduplication
Signed-off-by: szaimen <szaimen@e.mail.de>
This commit is contained in:
parent
9d4c591f1a
commit
3118ecf385
7 changed files with 40 additions and 29 deletions
|
|
@ -101,7 +101,7 @@ class DockerController
|
|||
public function StartBackupContainerRestore(Request $request, Response $response, $args) : Response {
|
||||
$config = $this->configurationManager->GetConfig();
|
||||
$config['backup-mode'] = 'restore';
|
||||
$config['selected-restore-time'] = $request->getParsedBody()['selected_restore_time'];
|
||||
$config['selected-restore-time'] = $request->getParsedBody()['selected_restore_time'] ?? '';
|
||||
$this->configurationManager->WriteConfig($config);
|
||||
|
||||
$id = self::TOP_CONTAINER;
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ class LoginController
|
|||
if (!$this->dockerActionManager->isLoginAllowed()) {
|
||||
return $response->withHeader('Location', '/')->withStatus(302);
|
||||
}
|
||||
$password = $request->getParsedBody()['password'];
|
||||
$password = $request->getParsedBody()['password'] ?? '';
|
||||
if($this->authManager->CheckCredentials($password)) {
|
||||
$this->authManager->SetAuthState(true);
|
||||
return $response->withHeader('Location', '/')->withStatus(302);
|
||||
|
|
@ -33,7 +33,7 @@ class LoginController
|
|||
}
|
||||
|
||||
public function GetTryLogin(Request $request, Response $response, $args) : Response {
|
||||
$token = $request->getQueryParams()['token'];
|
||||
$token = $request->getQueryParams()['token'] ?? '';
|
||||
if($this->authManager->CheckToken($token)) {
|
||||
$this->authManager->SetAuthState(true);
|
||||
return $response->withHeader('Location', '/')->withStatus(302);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue