Fix setting DM room name at creation

This commit is contained in:
Tulir Asokan 2023-07-09 14:57:54 +03:00
parent 1615e146b6
commit 7e90ec8c14

View file

@ -597,7 +597,8 @@ func (portal *Portal) UpdateBridgeInfo() {
func (portal *Portal) shouldSetDMRoomMetadata() bool {
return !portal.IsPrivateChat() ||
portal.bridge.Config.Bridge.PrivateChatPortalMeta == "always" ||
(portal.IsEncrypted() && portal.bridge.Config.Bridge.PrivateChatPortalMeta != "never")
((portal.IsEncrypted() || (portal.MXID == "" && portal.bridge.Config.Bridge.Encryption.Default)) &&
portal.bridge.Config.Bridge.PrivateChatPortalMeta != "never")
}
func (portal *Portal) GetEncryptionEventContent() (evt *event.EncryptionEventContent) {