matrix-sdk: (fix) use macro for matching in are_events_visible

master
SaurusXI 2021-06-21 20:14:40 +05:30
parent ae5be67322
commit 58369fe7d0
No known key found for this signature in database
GPG Key ID: 443CCBEAA2C0E87E
1 changed files with 4 additions and 4 deletions

View File

@ -184,10 +184,10 @@ impl Common {
fn are_events_visible(&self) -> bool { fn are_events_visible(&self) -> bool {
if let RoomType::Invited = self.inner.room_type() { if let RoomType::Invited = self.inner.room_type() {
return match self.inner.history_visibility() { return matches!(
HistoryVisibility::WorldReadable | HistoryVisibility::Invited => true, self.inner.history_visibility(),
_ => false, HistoryVisibility::WorldReadable | HistoryVisibility::Invited
}; );
} }
true true