do not overwrite global user auth credentials with empty values
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
This commit is contained in:
parent
f11e4c9ec4
commit
7e1d14d9a5
|
@ -56,6 +56,11 @@ class UserGlobalAuth extends AuthMechanism {
|
||||||
}
|
}
|
||||||
|
|
||||||
public function saveBackendOptions(IUser $user, $id, $backendOptions) {
|
public function saveBackendOptions(IUser $user, $id, $backendOptions) {
|
||||||
|
// backendOptions are set when invoked via Files app
|
||||||
|
// but they are not set when invoked via ext storage settings
|
||||||
|
if(!isset($backendOptions['user']) && !isset($backendOptions['password'])) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
// make sure we're not setting any unexpected keys
|
// make sure we're not setting any unexpected keys
|
||||||
$credentials = [
|
$credentials = [
|
||||||
'user' => $backendOptions['user'],
|
'user' => $backendOptions['user'],
|
||||||
|
|
Loading…
Reference in New Issue