fix: Atlassian Crowd integration doesn't work - #31391
Conversation
🦋 Changeset detectedLatest commit: 40e17bd The changes in this PR will be included in the next version bump. This PR includes changesets to release 30 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #31391 +/- ##
============================================
+ Coverage 49.58% 59.86% +10.27%
============================================
Files 3311 1795 -1516
Lines 81396 34929 -46467
Branches 16696 7273 -9423
============================================
- Hits 40361 20909 -19452
+ Misses 36330 12410 -23920
+ Partials 4705 1610 -3095
Flags with carried forward coverage won't be shown. Click here to find out more. |
89b0d71
There was a problem hiding this comment.
Found and fixed another issue with our Atlassian Crowd integration. This new crowd package doesn't always return users' ids on authentication (which were expected on our side), so we'd never consider a crowd authenticated user as new. That's because we'd apply a mongo filter such as _id: undefined, which could return any user -- so they'd instead take over someone else's account in the workspace 😬
I've added a new fallback for this case by linking a crowd authenticated user to a RC user by crowd_username or email.
Thanks @janainaCoelhoRocketchat for noticing that
Proposed changes (including videos or screenshots)
atlassian-crowd-patchedpackage usage. It does not work as async, so we should use its functions' callback params instead in order to retrieve its results;Issue(s)
Fixes #29285
Fixes #30932
Steps to test or reproduce
Further comments
Introduced by #28680
SUP-418