Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Delete matches when a user changes their phone number
Signed-off-by: Joas Schilling <[email protected]>
  • Loading branch information
nickvergessen committed Mar 11, 2021
commit 19ccc992d5be9a3e493dda8c2c5f4c00ab7ba8bc
4 changes: 4 additions & 0 deletions apps/provisioning_api/lib/Controller/UsersController.php
Original file line number Diff line number Diff line change
Expand Up @@ -686,6 +686,10 @@ public function editUser(string $userId, string $key, string $value): DataRespon
$userAccount[$key]['value'] = $value;
try {
$this->accountManager->updateUser($targetUser, $userAccount, true);

if ($key === IAccountManager::PROPERTY_PHONE) {
$this->knownUserMapper->deleteKnownUser($targetUser->getUID());
}
} catch (\InvalidArgumentException $e) {
throw new OCSException('Invalid ' . $e->getMessage(), 102);
}
Expand Down