mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-14 12:43:40 +02:00
Introduce (and use) an IsArgSet accessor method
This commit is contained in:
parent
2b5f085ad1
commit
0cf86a6678
12 changed files with 44 additions and 31 deletions
|
|
@ -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" +
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue