Skip to content

Commit 55ccfef

Browse files
authored
Merge pull request #19316 from nextcloud/backport/19312/stable17
[stable17] do not overwrite global user auth credentials with empty values
2 parents 728dae5 + 12ca2e3 commit 55ccfef

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

apps/files_external/lib/Lib/Auth/Password/UserGlobalAuth.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,11 @@ public function __construct(IL10N $l, ICredentialsManager $credentialsManager) {
5050
}
5151

5252
public function saveBackendOptions(IUser $user, $id, $backendOptions) {
53+
// backendOptions are set when invoked via Files app
54+
// but they are not set when invoked via ext storage settings
55+
if(!isset($backendOptions['user']) && !isset($backendOptions['password'])) {
56+
return;
57+
}
5358
// make sure we're not setting any unexpected keys
5459
$credentials = [
5560
'user' => $backendOptions['user'],

0 commit comments

Comments
 (0)