Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ID-1109 Fix Admin PATCH User Endpoint #1362

Merged
merged 1 commit into from
Feb 23, 2024

Conversation

tlangs
Copy link
Contributor

@tlangs tlangs commented Feb 23, 2024

Ticket: https://broadworkbench.atlassian.net/browse/ID-1109

When using the admin PATCH User endpoint to update the googleSubjectId and azureB2CId for a user at the same time, a database exception occurs. In the query construction, the positions of the new IDs were swapped, meaning the azureB2CId was being saved as a googleSubjectId. Thankfully, the database disallowed the update, as the azureB2CId UUID was too long for the googleSubjectId column.

I've re-worked the logic and added a test to make sure setting both ids works correctly.


PR checklist

  • I've followed the instructions if I've made any changes to the API, especially if they're breaking changes
  • I've filled out the Security Risk Assessment (requires Broad Internal network access) and attached the result to the JIRA ticket

Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@tlangs tlangs merged commit 5048ba4 into develop Feb 23, 2024
18 of 19 checks passed
@tlangs tlangs deleted the tl_ID-1109_fix_admin_patch_user_endpoint branch February 23, 2024 16:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants