mirror of
https://github.com/girlbossceo/conduwuit.git
synced 2025-12-11 09:48:49 -05:00
further simplify get_missing_events; various log calls
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
94b107b42b
commit
b7109131e2
3 changed files with 29 additions and 40 deletions
|
|
@ -1,4 +1,4 @@
|
|||
use conduwuit::{debug_info, implement, utils::stream::ReadyExt};
|
||||
use conduwuit::{implement, utils::stream::ReadyExt};
|
||||
use futures::StreamExt;
|
||||
use ruma::{
|
||||
EventId, RoomId, ServerName,
|
||||
|
|
@ -36,7 +36,6 @@ pub async fn server_can_see_event(
|
|||
.ready_filter(|member| member.server_name() == origin);
|
||||
|
||||
match history_visibility {
|
||||
| HistoryVisibility::WorldReadable | HistoryVisibility::Shared => true,
|
||||
| HistoryVisibility::Invited => {
|
||||
// Allow if any member on requesting server was AT LEAST invited, else deny
|
||||
current_server_members
|
||||
|
|
@ -49,9 +48,6 @@ pub async fn server_can_see_event(
|
|||
.any(|member| self.user_was_joined(shortstatehash, member))
|
||||
.await
|
||||
},
|
||||
| _ => {
|
||||
debug_info!(%room_id, "Unknown history visibility, defaulting to shared: {history_visibility:?}");
|
||||
true
|
||||
},
|
||||
| HistoryVisibility::WorldReadable | HistoryVisibility::Shared | _ => true,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue