Add check in sync space command and update changelog

This commit is contained in:
Tulir Asokan 2021-12-29 21:52:29 +02:00
parent ba536f17e7
commit 8168d0efff
2 changed files with 9 additions and 0 deletions

View file

@ -3,10 +3,15 @@
* Added support for bridging incoming broadcast list messages.
* Added overrides for mime type -> file extension mapping as some OSes have
very obscure extensions in their mime type database.
* Added support for personal filtering spaces (started by [@HelderFSFerreira] and [@clmnin] in [#413]).
* Fixed avatar remove events from WhatsApp being ignored.
* Fixed the bridge using the wrong Olm session if a client established a new
one due to corruption.
[@HelderFSFerreira]: https://github.com/HelderFSFerreira
[@clmnin]: https://github.com/clmnin
[#413]: https://github.com/mautrix/whatsapp/pull/413
# v0.2.2 (2021-12-16)
**This release includes a fix for a moderate severity security issue that

View file

@ -1102,6 +1102,10 @@ func (handler *CommandHandler) CommandSync(ce *CommandEvent) {
}
}
if space {
if !ce.Bridge.Config.Bridge.PersonalFilteringSpaces {
ce.Reply("Personal filtering spaces are not enabled on this instance of the bridge")
return
}
keys := ce.Bridge.DB.Portal.FindPrivateChatsNotInSpace(ce.User.JID)
count := 0
for _, key := range keys {