aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2021-12-29 14:58:35 +0100
committerGitHub <noreply@github.com>2021-12-29 14:58:35 +0100
commita37909f61c5850bfba9df42cb69d18ecce9710bc (patch)
tree976dd420aaa1332fa9b1c20ab58e1403a30943e0 /lib/private
parentde2b86a7a4c4fb244e9a73f805908f15f47a8626 (diff)
parente00173a71b5d8e24543c7a33701adb6b5e313077 (diff)
downloadnextcloud-server-a37909f61c5850bfba9df42cb69d18ecce9710bc.tar.gz
nextcloud-server-a37909f61c5850bfba9df42cb69d18ecce9710bc.zip
Merge pull request #29530 from nextcloud/bugfix/noid/username-prefill
Diffstat (limited to 'lib/private')
-rw-r--r--lib/private/AppFramework/Middleware/Security/SecurityMiddleware.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/private/AppFramework/Middleware/Security/SecurityMiddleware.php b/lib/private/AppFramework/Middleware/Security/SecurityMiddleware.php
index d162bb54108..fffeffd4feb 100644
--- a/lib/private/AppFramework/Middleware/Security/SecurityMiddleware.php
+++ b/lib/private/AppFramework/Middleware/Security/SecurityMiddleware.php
@@ -260,6 +260,10 @@ class SecurityMiddleware extends Middleware {
if (isset($this->request->server['REQUEST_URI'])) {
$params['redirect_url'] = $this->request->server['REQUEST_URI'];
}
+ $usernamePrefill = $this->request->getParam('user', '');
+ if ($usernamePrefill !== '') {
+ $params['user'] = $usernamePrefill;
+ }
$url = $this->urlGenerator->linkToRoute('core.login.showLoginForm', $params);
$response = new RedirectResponse($url);
} else {