fixed pexinfo

This commit is contained in:
Dmitry Zuikov 2023-07-27 09:43:51 +03:00
parent c2c80fc6f0
commit b83e472057
1 changed files with 8 additions and 1 deletions

View File

@ -240,6 +240,9 @@ runRpcCommand opt = \case
ANNOUNCE h -> withRPC opt (RPCAnnounce h)
FETCH h -> withRPC opt (RPCFetch h)
PEERS -> withRPC opt RPCPeers
PEXINFO -> withRPC opt RPCPexInfo
SETLOG s -> withRPC opt (RPCLogLevel s)
REFLOGUPDATE bs -> withRPC opt (RPCRefLogUpdate bs)
REFLOGFETCH k -> withRPC opt (RPCRefLogFetch k)
@ -301,7 +304,7 @@ withRPC o cmd = rpcClientMain o $ runResourceT do
, rpcOnPeers = dontHandle
, rpcOnPeersAnswer = (\(pa, k) -> Log.info $ pretty (AsBase58 k) <+> pretty pa)
, rpcOnPexInfo = dontHandle
, rpcOnPexInfoAnswer = dontHandle
, rpcOnPexInfoAnswer = (\ps -> mapM_ (Log.info . pretty) ps)
, rpcOnLogLevel = dontHandle
, rpcOnRefLogUpdate = dontHandle
, rpcOnRefLogFetch = dontHandle
@ -360,6 +363,10 @@ withRPC o cmd = rpcClientMain o $ runResourceT do
pause @'Seconds 1
exitSuccess
RPCPexInfo{} -> liftIO do
pause @'Seconds 1
exitSuccess
RPCLogLevel{} -> liftIO exitSuccess
RPCRefLogUpdate{} -> liftIO do