summaryrefslogtreecommitdiff
path: root/src/Network.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Network.hs')
-rw-r--r--src/Network.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/Network.hs b/src/Network.hs
index c9a2d8b..7195129 100644
--- a/src/Network.hs
+++ b/src/Network.hs
@@ -4,7 +4,7 @@ module Network (
getNextPeerChange,
ServerOptions(..), serverIdentity, defaultServerOptions,
- Peer, peerServer,
+ Peer, peerServer, peerStorage,
PeerAddress(..), peerAddress,
PeerIdentity(..), peerIdentity,
PeerChannel(..),
@@ -101,7 +101,7 @@ data Peer = Peer
, peerServer_ :: Server
, peerIdentityVar :: TVar PeerIdentity
, peerChannel :: TVar PeerChannel
- , peerStorage :: Storage
+ , peerStorage_ :: Storage
, peerInStorage :: PartialStorage
, peerOutQueue :: TQueue (Bool, [TransportHeaderItem], TransportPacket)
, peerSentPackets :: TVar [SentPacket]
@@ -120,6 +120,9 @@ data SentPacket = SentPacket
peerServer :: Peer -> Server
peerServer = peerServer_
+peerStorage :: Peer -> Storage
+peerStorage = peerStorage_
+
instance Eq Peer where
(==) = (==) `on` peerIdentityVar