forked from MirrorHub/mautrix-whatsapp
Update bridge info after updating community space
This commit is contained in:
parent
fea1fa6535
commit
6f635a66fc
1 changed files with 3 additions and 2 deletions
|
@ -1738,7 +1738,7 @@ func (portal *Portal) removeSpaceParentEvent(space id.RoomID) {
|
|||
}
|
||||
}
|
||||
|
||||
func (portal *Portal) updateCommunitySpace(user *User, add, updateDB bool) bool {
|
||||
func (portal *Portal) updateCommunitySpace(user *User, add, updateInfo bool) bool {
|
||||
if add == portal.InSpace {
|
||||
return false
|
||||
}
|
||||
|
@ -1781,8 +1781,9 @@ func (portal *Portal) updateCommunitySpace(user *User, add, updateDB bool) bool
|
|||
portal.log.Warnfln("Failed to send m.space.parent event to %s %s: %v", action, space.MXID, err)
|
||||
}
|
||||
portal.InSpace = add
|
||||
if updateDB {
|
||||
if updateInfo {
|
||||
portal.Update(nil)
|
||||
portal.UpdateBridgeInfo()
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue