This repository was archived by the owner on Sep 11, 2024. It is now read-only.
Filter out upgraded rooms from autocomplete results#2830
Merged
Conversation
Fixes element-hq/element-web#9289 Theory is that this shouldn't happen in the first place (aliases should be transferred), but there's evidently some cases where this doesn't work, or gets state reset.
bwindels
approved these changes
Mar 27, 2019
| const tombstone = r.room.currentState.getStateEvents("m.room.tombstone", ""); | ||
| if (tombstone && tombstone.getContent() && tombstone.getContent()['replacement_room']) { | ||
| console.log(r.displayedAlias); | ||
| const hasReplacementRoom = matcherObjects.some( |
Contributor
There was a problem hiding this comment.
This inner loop could slow down with big accounts I suppose? Wouldn't it be enough to exclude any rooms that have a tombstone event?
Member
Author
There was a problem hiding this comment.
There's the possibility that, for some reason, the user hasn't joined the upgraded room and the alias is still pointing at the old room. Out of abundance of caution, we might as well verify the room. On my massive account of ~2000 rooms, there's no noticeable performance impact of adding this check (in fact, it feels faster...)
su-ex
added a commit
to SchildiChat/matrix-react-sdk
that referenced
this pull request
Nov 4, 2022
* Fix default behavior of Room.getBlacklistUnverifiedDevices ([\matrix-org#2830](matrix-org/matrix-js-sdk#2830)). Contributed by @duxovni. * Catch server versions API call exception when starting the client ([\matrix-org#2828](matrix-org/matrix-js-sdk#2828)). Fixes element-hq/element-web#23634. * Fix authedRequest including `Authorization: Bearer undefined` for password resets ([\matrix-org#2822](matrix-org/matrix-js-sdk#2822)). Fixes element-hq/element-web#23655.
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Fixes element-hq/element-web#9289
Theory is that this shouldn't happen in the first place (aliases should be transferred), but there's evidently some cases where this doesn't work, or gets state reset.