mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-11-22 03:56:44 +01:00
multi: add a rpc endpoint to track the recovery process
This commit is contained in:
@@ -1729,6 +1729,27 @@ func getInfo(ctx *cli.Context) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
var getRecoveryInfoCommand = cli.Command{
|
||||
Name: "getrecoveryinfo",
|
||||
Usage: "Display information about an ongoing recovery attempt.",
|
||||
Action: actionDecorator(getRecoveryInfo),
|
||||
}
|
||||
|
||||
func getRecoveryInfo(ctx *cli.Context) error {
|
||||
ctxb := context.Background()
|
||||
client, cleanUp := getClient(ctx)
|
||||
defer cleanUp()
|
||||
|
||||
req := &lnrpc.GetRecoveryInfoRequest{}
|
||||
resp, err := client.GetRecoveryInfo(ctxb, req)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
printRespJSON(resp)
|
||||
return nil
|
||||
}
|
||||
|
||||
var pendingChannelsCommand = cli.Command{
|
||||
Name: "pendingchannels",
|
||||
Category: "Channels",
|
||||
|
||||
Reference in New Issue
Block a user