1
0
mirror of https://gitlab.com/comunic/comunicapiv3 synced 2025-01-01 00:18:50 +00:00

Reformat code

This commit is contained in:
Pierre HUBERT 2020-06-15 10:47:34 +02:00
parent 856d22fed8
commit 203a947122

View File

@ -128,7 +128,7 @@ pub fn can_everyone_add_members(conv_id: u64) -> ResultBoxError<bool> {
database::QueryInfo::new(CONV_LIST_TABLE) database::QueryInfo::new(CONV_LIST_TABLE)
.cond_u64("id", conv_id) .cond_u64("id", conv_id)
.add_field("can_everyone_add_members") .add_field("can_everyone_add_members")
.query_row(|f|f.get_legacy_bool("can_everyone_add_members")) .query_row(|f| f.get_legacy_bool("can_everyone_add_members"))
} }
/// Set whether a user is following a conversation or not /// Set whether a user is following a conversation or not
@ -153,6 +153,7 @@ pub fn set_members(conv_id: u64, new_list: &Vec<UserID>, can_delete: bool) -> Re
add_member(conv_id, member.clone(), true)?; add_member(conv_id, member.clone(), true)?;
} }
// Remove a member
if can_delete { if can_delete {
for member in curr_list { for member in curr_list {
if new_list.contains(&member) { if new_list.contains(&member) {