Always log when skipping a zaddr during z_importwallet
This commit is contained in:
@@ -515,14 +515,15 @@ UniValue importwallet_impl(const UniValue& params, bool fHelp, bool fImportZKeys
|
||||
auto addResult = boost::apply_visitor(
|
||||
AddSpendingKeyToWallet(pwalletMain, Params().GetConsensus(), nTime, hdKeypath, seedFpStr, true), spendingkey);
|
||||
if (addResult == KeyAlreadyExists){
|
||||
LogPrint("zrpc", "Skipping import of zaddr (key already present)\n");
|
||||
LogPrintf("%s: Skipping import of zaddr (key already present)\n", __func__);
|
||||
} else if (addResult == KeyNotAdded) {
|
||||
// Something went wrong
|
||||
fGood = false;
|
||||
LogPrintf("%s: Skipping import of zaddr (something went wrong)\n", __func__);
|
||||
}
|
||||
continue;
|
||||
} else {
|
||||
LogPrint("zrpc", "Importing detected an error: invalid spending key. Trying as a transparent key...\n");
|
||||
LogPrintf("%s: Importing detected an error: invalid spending key. Trying as a transparent key...\n",__func__);
|
||||
// Not a valid spending key, so carry on and see if it's a Hush transparent address
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user