-
Notifications
You must be signed in to change notification settings - Fork 509
Fix redirect when deleting current conversation #5082
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
Conversation
|
/backport to stable21 |
|
@nickvergessen I've pushed a fix to prevent leaving or deleting a conversation while in a call. This will prevent the can of worms of trying to handle warning dialogs, etc. As a bonus I also added a "close that freaky popup already when I click". Regarding router push, see my comment above. It's also a can of worms. |
a68ac9a to
67c21a2
Compare
|
I've changed the approach. The new approach doesn't refactor the old code. Since we'll need this kind of handling outside of App.vue, I've put the code into the mixin duplicateSessionHandler which I renamed to sessionIssueHandler. Cases to cover and test all while in a call:
|
|
looks like we were redirecting to talk's "duplicate session" page already in a sidebar call, despite being in the files app :-/ |
|
it seems that when deleting the current conversation there's already another handler that sets the route before it reaches the sessionIssueHandler, this is what triggers that dialog. |
|
Aha, finally found something: when setting the route to not-found it doesn't automatically clear the token, this is why I've seen a lot of JS errors because the right sidebar is still present with its chat tab. |
When the current conversation was deleted while in a call, or whenever someone has been removed from a room, the redirect now targets the not-found page instead of the one about duplicate session. Signed-off-by: Vincent Petry <[email protected]>
67c21a2 to
2999b5d
Compare
|
After some research and tests I realized the following:
@nickvergessen please re-review |
|
@nickvergessen any concerns against merging this ? I've noticed this might tie in with my discovery in #4670 (comment) where we could also make the "go to not found" event only work if the token we're leaving is also the one on the page. |
This comment has been minimized.
This comment has been minimized.
|
When I tested in chromium back then I didn't see the browser's native dialog, because now we're using the router, it should switch you to the "not found" page without a page refresh. Strange that it didn't work. I'll recheck and test with Firefox then. |
|
With the following I did not see any browser dialog:
=> in the admin browser I land on the welcome page Not sure if you used different steps or if it's a cache issue ? |
|
/backport to stable21.1 |
|
So I'm currently on the "Not found" page with Ivan in a call. We still hear each others as the webrtc stuff all didn't get canceled, but we can't change mic/camera/screenshare status anymore. So I propose to go back to the redirect at least while being in a call. |
PR here: #5595 |
When the current conversation was deleted while in a call, the redirect
now targets the not-found page instead of the one about duplicate
session.
Added event bus handler for the not found page which now also removes
the session store's conversation token.
Fixes #4552