[WPB-22154] fix: move user between SCIM tokens#4887
Merged
Conversation
a7ca267 to
b1bf345
Compare
b1bf345 to
9c95b9a
Compare
It's slightly less insane now, but it does change behavior in some (untested) corner cases.
fisx
commented
Dec 9, 2025
Contributor
Author
fisx
left a comment
There was a problem hiding this comment.
two minor observations
services/spar/src/Spar/Scim/User.hs
Outdated
| Right veid -> lift $ do | ||
| for_ (justThere veid.validScimIdAuthInfo) (SAMLUserStore.delete uid) | ||
| ScimExternalIdStore.delete stiTeam veid.validScimIdExternal | ||
| lift $ ScimUserTimesStore.delete uid -- TODO: is this removing the record owned by caller of this end-point (ie., team owner), or correct one?! |
Comment on lines
1331
to
1330
| mbEmail = | ||
| (emailIdentity =<< memberWithSSO.userIdentity) | ||
| <|> memberWithSSO.userEmailUnvalidated | ||
| externalId = either error id $ veidToText =<< Intra.newVeidFromBrigUser memberWithSSO (Just idpIssuer) mbEmail | ||
| externalId = either error id $ veidToText =<< Intra.newVeidFromBrigUser memberWithSSO (Just idpIssuer) |
Contributor
Author
There was a problem hiding this comment.
here the semantics was actually correct, just really convoluted. now this what newVeidFromBrigUser always does.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://wearezeta.atlassian.net/browse/WPB-22154
Checklist
changelog.d