diff options
author | Joas Schilling <coding@schilljs.com> | 2024-11-19 18:02:22 +0100 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2024-11-19 18:02:22 +0100 |
commit | 394febb5d9f1ada1c6dfd0316a6a994b87c7148a (patch) | |
tree | 3e0d80bbec76992f61e3adec5eaa7381006d0108 /lib | |
parent | 4d85f44c9f3c73ed13434e450f97718a29ea2e66 (diff) | |
download | nextcloud-server-394febb5d9f1ada1c6dfd0316a6a994b87c7148a.tar.gz nextcloud-server-394febb5d9f1ada1c6dfd0316a6a994b87c7148a.zip |
fix(userconfig): Don't fail the precondition if the value is not set at allbugfix/47658/dont-fail-precondition-if-unset
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/AllConfig.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/AllConfig.php b/lib/private/AllConfig.php index bb15adf31b4..72af6c960a5 100644 --- a/lib/private/AllConfig.php +++ b/lib/private/AllConfig.php @@ -246,7 +246,7 @@ class AllConfig implements IConfig { $userPreferences = \OCP\Server::get(IUserConfig::class); if ($preCondition !== null) { try { - if ($userPreferences->getValueMixed($userId, $appName, $key) !== (string)$preCondition) { + if ($userPreferences->hasKey($userId, $appName, $key) && $userPreferences->getValueMixed($userId, $appName, $key) !== (string)$preCondition) { throw new PreConditionNotMetException(); } } catch (TypeConflictException) { |