From f187c66d693b311b19e45206fd0c15d5143c8105 Mon Sep 17 00:00:00 2001 From: Pere Lev Date: Wed, 13 Mar 2024 15:35:50 +0200 Subject: [PATCH] S2S: Group: Accept: Fix bug, collab approval wasn't working --- src/Vervis/Actor/Group.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Vervis/Actor/Group.hs b/src/Vervis/Actor/Group.hs index 22ab360..4d6c414 100644 --- a/src/Vervis/Actor/Group.hs +++ b/src/Vervis/Actor/Group.hs @@ -200,7 +200,7 @@ groupAccept now groupID (Verse authorIdMsig body) accept = do case (collab, acceptDB) of (Left (fulfillsID, Left recipID), Left (_, _, acceptID)) -> do maybeAccept <- lift $ insertUnique $ CollabRecipLocalAccept recipID fulfillsID acceptID - unless (isNothing maybeAccept) $ + unless (isJust maybeAccept) $ throwE "This Invite already has an Accept by recip" (Left (fulfillsID, Right recipID), Right (_, _, acceptID)) -> do maybeAccept <- lift $ insertUnique $ CollabRecipRemoteAccept recipID fulfillsID acceptID