summaryrefslogtreecommitdiff
path: root/src/Network/BitTorrent/DHT/Session.hs
diff options
context:
space:
mode:
authorSam Truzjan <pxqr.sta@gmail.com>2014-02-16 23:59:52 +0400
committerSam Truzjan <pxqr.sta@gmail.com>2014-02-16 23:59:52 +0400
commit677c54a4ed4e4ecb185b46a8272add4c6df04b0b (patch)
tree542e2a49e3c1d25d893e2254cb88ff54bbdc2b98 /src/Network/BitTorrent/DHT/Session.hs
parent81fb820ce0469a7ff3677e278ed5e3b3c491f569 (diff)
Move ping function to Query module
Diffstat (limited to 'src/Network/BitTorrent/DHT/Session.hs')
-rw-r--r--src/Network/BitTorrent/DHT/Session.hs6
1 files changed, 0 insertions, 6 deletions
diff --git a/src/Network/BitTorrent/DHT/Session.hs b/src/Network/BitTorrent/DHT/Session.hs
index 11e1c81a..6f13cf78 100644
--- a/src/Network/BitTorrent/DHT/Session.hs
+++ b/src/Network/BitTorrent/DHT/Session.hs
@@ -55,7 +55,6 @@ module Network.BitTorrent.DHT.Session
55 , queryNode 55 , queryNode
56 , queryParallel 56 , queryParallel
57 , (<@>) 57 , (<@>)
58 , ping
59 ) where 58 ) where
60 59
61import Prelude hiding (ioError) 60import Prelude hiding (ioError)
@@ -463,8 +462,3 @@ queryParallel queries = do
463 where 462 where
464 cleanup :: [Either QueryFailure a] -> [a] 463 cleanup :: [Either QueryFailure a] -> [a]
465 cleanup = mapMaybe (either (const Nothing) Just) 464 cleanup = mapMaybe (either (const Nothing) Just)
466
467ping :: Address ip => NodeAddr ip -> DHT ip (NodeInfo ip)
468ping addr = do
469 (nid, Ping) <- queryNode addr Ping
470 return (NodeInfo nid addr)