diff --git a/lib/private/Profile/ProfileManager.php b/lib/private/Profile/ProfileManager.php index ddc0670604b55..696b03186fdb3 100644 --- a/lib/private/Profile/ProfileManager.php +++ b/lib/private/Profile/ProfileManager.php @@ -385,6 +385,7 @@ public function getProfileConfig(IUser $targetUser, ?IUser $visitingUser): array $this->filterNotStoredProfileConfig($config->getConfigArray()), )); $this->configMapper->update($config); + $this->configCache[$targetUser->getUID()] = $config; $configArray = $config->getConfigArray(); } catch (DoesNotExistException $e) { // Create a new default config if it does not exist @@ -392,6 +393,7 @@ public function getProfileConfig(IUser $targetUser, ?IUser $visitingUser): array $config->setUserId($targetUser->getUID()); $config->setConfigArray($defaultProfileConfig); $this->configMapper->insert($config); + $this->configCache[$targetUser->getUID()] = $config; $configArray = $config->getConfigArray(); }