Repository navigation
Updated invitation flow - #1078
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #1078 +/- ##
============================================
+ Coverage 89.06% 89.17% +0.11%
- Complexity 1875 1991 +116
============================================
Files 275 282 +7
Lines 9733 9833 +100
============================================
+ Hits 8669 8769 +100
Misses 1064 1064 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
b68825c to
3267acb
Compare
|
|
||
| $user->switchTeam($organization); | ||
|
|
||
| // Note: The refresh is necessary for currently unknown reasons. Do not remove it. |
There was a problem hiding this comment.
do we know why it is needed now?
There was a problem hiding this comment.
Do you mean the switchTeam or the refresh?
There was a problem hiding this comment.
The refresh. The comment just sounded like a leftover.
There was a problem hiding this comment.
Yes this might be a leftover, but I'll move the switchTeam to the UserService anyways to further reduce the dependency on Jetstream and then remove the refresh.
|
@korridor I did change it to a session state now after all because the Inertia URL handling gets flaky once I start messing with the URLs on the client side (Inertia has its own URL state, which overrides it again). We can revisit this when we eventually migrate to a SPA and have full URL control there. E2E tests are in place so it should be an easy migration after the fact. I also changed the logged-out redirect and added an Auth check there for the case detection. I think this is cleaner than messing with the middleware behaviour and I don't really see a reason why there shouldn't be an Auth check in this controller especially when we just use it for the determining the redirect. Arguably, the UX path for "A different user is logged in and accepts the invite" is a bit confusing because they get a message that they accepted an invite to an organization but the logged in user cannot actually see the org (because the invite was accepted for a different user). It is probably an edge case tho. |
|
the photo delete path was not supported, it now takes |
|
@korridor there is currently no way to reset the email_pending as far as I can see. so when you change the email address but decide afterwards that you actually don't wanna change it, it just stays in email_pending forever. we could either make it so that the endpoint resets |
61ae1f2 to
c8623b7
Compare
|
profile information update and user delete are now moved to the API. I do the password check manually now in the frontend and confirm it with the fortify password.confirm route, technically it is however way easier now to just straight up delete the account with an endpoint or caused by some rogue script/extension. we could add a password check/middleware again to the delete endpoint, not sure if its really necessary tho. it would be kinda weird for an API endpoint. |
71a7eeb to
f32ec59
Compare
532d74a to
7035d5f
Compare
|
Before merge: merge pull requests in extensions |
16dcb5d to
98bbe80
Compare
|
it looks like |
5384152 to
f826474
Compare
@Onatcer Fixed in latest commit "Fixed current organization after normal registration" |
1a4d858 to
3caf743
Compare
49c0891 to
4ff8a72
Compare
|
@korridor everything that was caught by the e2e tests is now fixed, so from what i can tell this is ready for merge. I added one comment about the AuthenticateSession middleware that you might want to look at. One more security related thing: Because the user delete endpoint is now in the API and does not require a password anymore, it is less protected against potential XSS attacks (the UI checks the password first but the API endpoint does not). I'm leaning towards requiring the password there again especially because the enpoint is also accessible with an API token now. |
|
@Onatcer Thanks.
Sounds good especially since there are a lot of self-hosters, but would the same argument be true for |
|
@korridor agreed, i think adding it to both of them is a good idea. one thing we should keep in mind is that users added via other identity providers (SSO) in the future might not have a password. |
4ff8a72 to
f8a2b7a
Compare
f8a2b7a to
f3ec660
Compare
What does this PR do?
Checklist (DO NOT REMOVE)
Sayr 42