From 1cc97b10d0350894972dca5fcdda04446ff6e6a9 Mon Sep 17 00:00:00 2001 From: wellweek Date: Fri, 21 Mar 2025 14:16:32 +0800 Subject: [PATCH] fix: fix the wrong error return value Signed-off-by: wellweek --- common/common.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/common.go b/common/common.go index 1002da4..7cef03d 100644 --- a/common/common.go +++ b/common/common.go @@ -258,7 +258,7 @@ func GetLightdInfo() (*walletrpc.LightdInfo, error) { var getinfoReply ZcashdRpcReplyGetinfo err := json.Unmarshal(result, &getinfoReply) if err != nil { - return nil, rpcErr + return nil, err } result, rpcErr = RawRequest("getblockchaininfo", []json.RawMessage{}) @@ -268,7 +268,7 @@ func GetLightdInfo() (*walletrpc.LightdInfo, error) { var getblockchaininfoReply ZcashdRpcReplyGetblockchaininfo err = json.Unmarshal(result, &getblockchaininfoReply) if err != nil { - return nil, rpcErr + return nil, err } // If the sapling consensus branch doesn't exist, it must be regtest var saplingHeight int