diff options
author | Roman Smrž <roman.smrz@seznam.cz> | 2025-05-29 22:30:40 +0200 |
---|---|---|
committer | Roman Smrž <roman.smrz@seznam.cz> | 2025-05-31 17:09:53 +0200 |
commit | 847b60ae7eb2d98576ed7e8775a690041fed8081 (patch) | |
tree | c81f208c53e0151d8be2869f32629cf36f09e6e3 /main/Test.hs | |
parent | d9800045d572358526bf18688f06a4cfa4f99772 (diff) |
Use weak refs in discovery service
Diffstat (limited to 'main/Test.hs')
-rw-r--r-- | main/Test.hs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/main/Test.hs b/main/Test.hs index 44818fd..a119b0f 100644 --- a/main/Test.hs +++ b/main/Test.hs @@ -957,11 +957,10 @@ cmdChatroomMessageSend = do cmdDiscoveryConnect :: Command cmdDiscoveryConnect = do - st <- asks tiStorage [ tref ] <- asks tiParams - Just ref <- liftIO $ readRef st $ encodeUtf8 tref + Just dgst <- return $ readRefDigest $ encodeUtf8 tref Just RunningServer {..} <- gets tsServer peers <- liftIO $ getCurrentPeerList rsServer forM_ peers $ \peer -> do - sendToPeer peer $ DiscoverySearch ref + sendToPeer peer $ DiscoverySearch $ Right dgst |