mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 14:38:29 +01:00
Introduce (and use) an IsArgSet accessor method
This commit is contained in:
@@ -76,9 +76,9 @@ static int AppInitRPC(int argc, char* argv[])
|
||||
// Parameters
|
||||
//
|
||||
ParseParameters(argc, argv);
|
||||
if (argc<2 || mapArgs.count("-?") || mapArgs.count("-h") || mapArgs.count("-help") || mapArgs.count("-version")) {
|
||||
if (argc<2 || IsArgSet("-?") || IsArgSet("-h") || IsArgSet("-help") || IsArgSet("-version")) {
|
||||
std::string strUsage = strprintf(_("%s RPC client version"), _(PACKAGE_NAME)) + " " + FormatFullVersion() + "\n";
|
||||
if (!mapArgs.count("-version")) {
|
||||
if (!IsArgSet("-version")) {
|
||||
strUsage += "\n" + _("Usage:") + "\n" +
|
||||
" bitcoin-cli [options] <command> [params] " + strprintf(_("Send command to %s"), _(PACKAGE_NAME)) + "\n" +
|
||||
" bitcoin-cli [options] help " + _("List commands") + "\n" +
|
||||
|
||||
Reference in New Issue
Block a user