Open Kritzefitz opened 1 year ago
Can you leave your main control room and rejoin it by creating a DM with Heisenbridge? The reason why it was never enabled was that when a room is considered direct creating a new DM would just open an existing room blocking it completely from talking with Heisenbridge again from some clients, including Element.
Can you leave your main control room and rejoin it by creating a DM with Heisenbridge?
Yes, this seems to work for me. The way I tested was:
status
a first message (element apparently only creates a dm room on first message)I guess this would be quite risky to merge, without thoroughly testing the behavior on various clients. What do you think about hiding this behavior behind a per-user setting? That way the impact of undesired client behavior can be mitigated by just not switching the feature on. Though I guess it might still lead to unpleasant situations, if a user is locked out of the main control room as in your scenario and then unable to switch the feature off.
This changes the creation logic for private rooms to use the
is_direct
flag, so the room will be correctly recognized as a direct chat. To prevent the created room from being recognized as a private chat with the bridge user, we create the room as the irc user and then invite the real user and bridge user into the room and change the power levels to give power to the bridge user and take it from the irc user. This should leave the room in the same state after creation as before the change, but the initial invite to the real user is sent from the irc user and not the bridge user. This should cause clients to correctly recognize the irc user as the direct chat partner instead of the bridge user. This works correctly on element web, though I have not tested the behavior in other clients.