summaryrefslogtreecommitdiff
path: root/src/Contact.hs
diff options
context:
space:
mode:
authorRoman Smrž <roman.smrz@seznam.cz>2020-12-20 21:47:22 +0100
committerRoman Smrž <roman.smrz@seznam.cz>2020-12-23 22:32:09 +0100
commit36b9a1ddbddf1477c61809d340cd0b86360a7a83 (patch)
tree7b327df1b1635270e98391ec1cf63478b8730793 /src/Contact.hs
parent0c4c6618d43a8b7179f11b8edb1f289169b5f2bc (diff)
Network: STM-based synchronization rewrite
Diffstat (limited to 'src/Contact.hs')
-rw-r--r--src/Contact.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Contact.hs b/src/Contact.hs
index 814e324..fefcd1f 100644
--- a/src/Contact.hs
+++ b/src/Contact.hs
@@ -121,7 +121,7 @@ contactAccept printMsg h peer = do
liftIO $ printMsg $ "Contact accepted, waiting for peer confirmation"
return (Nothing, OurRequestReady)
OurRequestConfirm (Just ContactAccepted) -> do
- PeerIdentityFull pid <- return $ peerIdentity peer
+ PeerIdentityFull pid <- peerIdentity peer
liftIO $ do
printMsg $ "Contact accepted"
updateLocalState_ h $ finalizeContact pid
@@ -129,7 +129,7 @@ contactAccept printMsg h peer = do
OurRequestReady -> throwError $ "alredy accepted, waiting for peer"
PeerRequest {} -> throwError $ "waiting for peer"
PeerRequestConfirm -> do
- PeerIdentityFull pid <- return $ peerIdentity peer
+ PeerIdentityFull pid <- peerIdentity peer
liftIO $ do
printMsg $ "Contact accepted"
updateLocalState_ h $ finalizeContact pid