sign server responses

This commit is contained in:
Evgeny Poberezkin
2021-12-15 11:52:09 +00:00
parent cf3d0dfdc3
commit 5aa0e97cd9
9 changed files with 128 additions and 102 deletions
@@ -42,14 +42,13 @@ instance MonadQueueStore QueueStore STM where
}
return $ Right ()
getQueue :: QueueStore -> SParty (p :: Party) -> QueueId -> STM (Either ErrorType QueueRec)
getQueue st party qId = do
getQueue :: QueueStore -> ClientParty -> QueueId -> STM (Either ErrorType QueueRec)
getQueue st (CP party) qId = do
cs <- readTVar st
pure $ case party of
SRecipient -> getRcpQueue cs qId
SSender -> getPartyQueue cs senders
SNotifier -> getPartyQueue cs notifiers
SBroker -> Left INTERNAL
where
getPartyQueue ::
QueueStoreData ->