From 3abaa60aa475ac5e7ed03139e9ec8d0d0117f510 Mon Sep 17 00:00:00 2001 From: Darius Date: Fri, 13 Dec 2024 15:48:22 -0600 Subject: [PATCH] chore: fmt --- extensions/warp-ipfs/src/store/message.rs | 8 +++---- .../warp-ipfs/src/store/message/task.rs | 24 +++++++++---------- 2 files changed, 15 insertions(+), 17 deletions(-) diff --git a/extensions/warp-ipfs/src/store/message.rs b/extensions/warp-ipfs/src/store/message.rs index 2516acb07..f4aa9c8bb 100644 --- a/extensions/warp-ipfs/src/store/message.rs +++ b/extensions/warp-ipfs/src/store/message.rs @@ -3353,11 +3353,9 @@ async fn process_identity_events( for id in list .iter() - .filter_map(|c| { - match c.inner { - InnerDocument::Direct(_) => None, - InnerDocument::Group(ref document) => Some((c.id, document)) - } + .filter_map(|c| match c.inner { + InnerDocument::Direct(_) => None, + InnerDocument::Group(ref document) => Some((c.id, document)), }) .filter(|(_, c)| c.restrict.contains(&did)) .map(|(id, _)| id) diff --git a/extensions/warp-ipfs/src/store/message/task.rs b/extensions/warp-ipfs/src/store/message/task.rs index 0765eee80..fa725c8f1 100644 --- a/extensions/warp-ipfs/src/store/message/task.rs +++ b/extensions/warp-ipfs/src/store/message/task.rs @@ -3167,8 +3167,8 @@ async fn message_event( let creator = &document.creator; if creator != sender && !document - .permissions - .has_permission(sender, GroupPermission::EditGroupInfo) + .permissions + .has_permission(sender, GroupPermission::EditGroupInfo) { return Err(Error::Unauthorized); } @@ -3209,8 +3209,8 @@ async fn message_event( let creator = &document.creator; if creator != sender && !document - .permissions - .has_permission(sender, GroupPermission::EditGroupInfo) + .permissions + .has_permission(sender, GroupPermission::EditGroupInfo) { return Err(Error::Unauthorized); } @@ -3234,8 +3234,8 @@ async fn message_event( let creator = &document.creator; if creator != sender && !document - .permissions - .has_permission(sender, GroupPermission::EditGroupInfo) + .permissions + .has_permission(sender, GroupPermission::EditGroupInfo) { return Err(Error::Unauthorized); } @@ -3273,8 +3273,8 @@ async fn message_event( let creator = &document.creator; if creator != sender && !document - .permissions - .has_permission(sender, GroupPermission::EditGroupInfo) + .permissions + .has_permission(sender, GroupPermission::EditGroupInfo) { return Err(Error::Unauthorized); } @@ -3295,8 +3295,8 @@ async fn message_event( let creator = &document.creator; if creator != sender && !document - .permissions - .has_permission(sender, GroupPermission::EditGroupInfo) + .permissions + .has_permission(sender, GroupPermission::EditGroupInfo) { return Err(Error::Unauthorized); } @@ -3315,8 +3315,8 @@ async fn message_event( let creator = &document.creator; if creator != sender && !document - .permissions - .has_permission(sender, GroupPermission::EditGroupInfo) + .permissions + .has_permission(sender, GroupPermission::EditGroupInfo) { return Err(Error::Unauthorized); }