mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-12-18 16:42:54 +01:00
Chainparams: Translations: DRY: options and error strings
Also remove SelectBaseParamsFromCommandLine and SelectParamsFromCommandLine
This commit is contained in:
@@ -604,8 +604,10 @@ int main(int argc, char *argv[])
|
||||
// - Needs to be done before createOptionsModel
|
||||
|
||||
// Check for -testnet or -regtest parameter (Params() calls are only valid after this clause)
|
||||
if (!SelectParamsFromCommandLine()) {
|
||||
QMessageBox::critical(0, QObject::tr("Bitcoin Core"), QObject::tr("Error: Invalid combination of -regtest and -testnet."));
|
||||
try {
|
||||
SelectParams(ChainNameFromCommandLine());
|
||||
} catch(std::exception &e) {
|
||||
QMessageBox::critical(0, QObject::tr("Bitcoin Core"), QObject::tr("Error: %1").arg(e.what()));
|
||||
return 1;
|
||||
}
|
||||
#ifdef ENABLE_WALLET
|
||||
|
||||
Reference in New Issue
Block a user