diff options
author | Jorge Timón <jtimon@jtimon.cc> | 2015-11-28 15:04:35 +0100 |
---|---|---|
committer | Jorge Timón <jtimon@jtimon.cc> | 2017-05-03 18:15:54 +0200 |
commit | 2351a064a604f5aa961a38a3920289546dada16f (patch) | |
tree | 6878027b39f34a4de14fa14b89304e11be322357 /src/qt/paymentserver.cpp | |
parent | f87f3626e35e7edae37e14f5156809325ad18cb2 (diff) |
Chainparams: Get rid of CChainParams& Params(std::string)
Diffstat (limited to 'src/qt/paymentserver.cpp')
-rw-r--r-- | src/qt/paymentserver.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/qt/paymentserver.cpp b/src/qt/paymentserver.cpp index dd75f12076..fdecb5cb1c 100644 --- a/src/qt/paymentserver.cpp +++ b/src/qt/paymentserver.cpp @@ -219,14 +219,16 @@ void PaymentServer::ipcParseCommandLine(int argc, char* argv[]) if (GUIUtil::parseBitcoinURI(arg, &r) && !r.address.isEmpty()) { CBitcoinAddress address(r.address.toStdString()); + auto tempChainParams = CreateChainParams(CBaseChainParams::MAIN); - if (address.IsValid(Params(CBaseChainParams::MAIN))) + if (address.IsValid(*tempChainParams)) { SelectParams(CBaseChainParams::MAIN); } - else if (address.IsValid(Params(CBaseChainParams::TESTNET))) - { - SelectParams(CBaseChainParams::TESTNET); + else { + tempChainParams = CreateChainParams(CBaseChainParams::TESTNET); + if (address.IsValid(*tempChainParams)) + SelectParams(CBaseChainParams::TESTNET); } } } |