mirror of https://github.com/voidlizard/hbs2
fixed pexinfo
This commit is contained in:
parent
c2c80fc6f0
commit
b83e472057
|
@ -240,6 +240,9 @@ runRpcCommand opt = \case
|
||||||
ANNOUNCE h -> withRPC opt (RPCAnnounce h)
|
ANNOUNCE h -> withRPC opt (RPCAnnounce h)
|
||||||
FETCH h -> withRPC opt (RPCFetch h)
|
FETCH h -> withRPC opt (RPCFetch h)
|
||||||
PEERS -> withRPC opt RPCPeers
|
PEERS -> withRPC opt RPCPeers
|
||||||
|
|
||||||
|
PEXINFO -> withRPC opt RPCPexInfo
|
||||||
|
|
||||||
SETLOG s -> withRPC opt (RPCLogLevel s)
|
SETLOG s -> withRPC opt (RPCLogLevel s)
|
||||||
REFLOGUPDATE bs -> withRPC opt (RPCRefLogUpdate bs)
|
REFLOGUPDATE bs -> withRPC opt (RPCRefLogUpdate bs)
|
||||||
REFLOGFETCH k -> withRPC opt (RPCRefLogFetch k)
|
REFLOGFETCH k -> withRPC opt (RPCRefLogFetch k)
|
||||||
|
@ -301,7 +304,7 @@ withRPC o cmd = rpcClientMain o $ runResourceT do
|
||||||
, rpcOnPeers = dontHandle
|
, rpcOnPeers = dontHandle
|
||||||
, rpcOnPeersAnswer = (\(pa, k) -> Log.info $ pretty (AsBase58 k) <+> pretty pa)
|
, rpcOnPeersAnswer = (\(pa, k) -> Log.info $ pretty (AsBase58 k) <+> pretty pa)
|
||||||
, rpcOnPexInfo = dontHandle
|
, rpcOnPexInfo = dontHandle
|
||||||
, rpcOnPexInfoAnswer = dontHandle
|
, rpcOnPexInfoAnswer = (\ps -> mapM_ (Log.info . pretty) ps)
|
||||||
, rpcOnLogLevel = dontHandle
|
, rpcOnLogLevel = dontHandle
|
||||||
, rpcOnRefLogUpdate = dontHandle
|
, rpcOnRefLogUpdate = dontHandle
|
||||||
, rpcOnRefLogFetch = dontHandle
|
, rpcOnRefLogFetch = dontHandle
|
||||||
|
@ -360,6 +363,10 @@ withRPC o cmd = rpcClientMain o $ runResourceT do
|
||||||
pause @'Seconds 1
|
pause @'Seconds 1
|
||||||
exitSuccess
|
exitSuccess
|
||||||
|
|
||||||
|
RPCPexInfo{} -> liftIO do
|
||||||
|
pause @'Seconds 1
|
||||||
|
exitSuccess
|
||||||
|
|
||||||
RPCLogLevel{} -> liftIO exitSuccess
|
RPCLogLevel{} -> liftIO exitSuccess
|
||||||
|
|
||||||
RPCRefLogUpdate{} -> liftIO do
|
RPCRefLogUpdate{} -> liftIO do
|
||||||
|
|
Loading…
Reference in New Issue