@@ -242,7 +242,7 @@ void protx_register_fund_help()
242242 " It has to match the private key which is later used when operating the masternode.\n "
243243 " 5. \" votingAddress\" (string, required) The voting key address. The private key does not have to be known by your wallet.\n "
244244 " It has to match the private key which is later used when voting on proposals.\n "
245- " If set to \" 0 \" or an empty string, ownerAddr will be used.\n "
245+ " If set to an empty string, ownerAddress will be used.\n "
246246 " 6. \" operatorReward\" (numeric, required) The fraction in % to share with the operator. The value must be\n "
247247 " between 0.00 and 100.00.\n "
248248 " 7. \" payoutAddress\" (string, required) The dash address to use for masternode reward payments.\n "
@@ -359,7 +359,7 @@ UniValue protx_register(const JSONRPCRequest& request)
359359 pwalletMain->LockCoin (ptx.collateralOutpoint );
360360 }
361361
362- if (request.params [paramIdx].get_str () != " 0 " && request. params [paramIdx]. get_str () != " " ) {
362+ if (request.params [paramIdx].get_str () != " " ) {
363363 if (!Lookup (request.params [paramIdx].get_str ().c_str (), ptx.addr , Params ().GetDefaultPort (), false )) {
364364 throw std::runtime_error (strprintf (" invalid network address %s" , request.params [paramIdx].get_str ()));
365365 }
@@ -368,7 +368,7 @@ UniValue protx_register(const JSONRPCRequest& request)
368368 CKey keyOwner = ParsePrivKey (request.params [paramIdx + 1 ].get_str (), true );
369369 CBLSPublicKey pubKeyOperator = ParseBLSPubKey (request.params [paramIdx + 2 ].get_str (), " operator BLS address" );
370370 CKeyID keyIDVoting = keyOwner.GetPubKey ().GetID ();
371- if (request.params [paramIdx + 3 ].get_str () != " 0 " && request. params [paramIdx + 3 ]. get_str () != " " ) {
371+ if (request.params [paramIdx + 3 ].get_str () != " " ) {
372372 keyIDVoting = ParsePubKeyIDFromAddress (request.params [paramIdx + 3 ].get_str (), " voting address" );
373373 }
374374
@@ -497,6 +497,7 @@ void protx_update_service_help()
497497 " registered operator public key.\n "
498498 " 4. \" operatorPayoutAddress\" (string, optional) The address used for operator reward payments.\n "
499499 " Only allowed when the ProRegTx had a non-zero operatorReward value.\n "
500+ " If set to an empty string, the currently active payout address is reused.\n "
500501 " 5. \" feeSourceAddress\" (string, optional) If specified wallet will only use coins from this address to fund ProTx.\n "
501502 " If not specified, operatorPayoutAddress is the one that is going to be used.\n "
502503 " The private key belonging to this address must be known in your wallet.\n "
@@ -535,7 +536,7 @@ UniValue protx_update_service(const JSONRPCRequest& request)
535536
536537 // param operatorPayoutAddress
537538 if (request.params .size () >= 5 ) {
538- if (request.params [4 ].get_str ().empty () || request. params [ 4 ]. get_str () == " 0 " ) {
539+ if (request.params [4 ].get_str ().empty ()) {
539540 ptx.scriptOperatorPayout = dmn->pdmnState ->scriptOperatorPayout ;
540541 } else {
541542 CBitcoinAddress payoutAddress (request.params [4 ].get_str ());
@@ -585,12 +586,12 @@ void protx_update_registrar_help()
585586 " 1. \" proTxHash\" (string, required) The hash of the initial ProRegTx.\n "
586587 " 2. \" operatorPubKey\" (string, required) The operator public key. The private key does not have to be known by you.\n "
587588 " It has to match the private key which is later used when operating the masternode.\n "
588- " If set to \" 0 \" or an empty string, the last on-chain operator key of the masternode will be used.\n "
589+ " If set to an empty string, the last on-chain operator key of the masternode will be used.\n "
589590 " 3. \" votingAddress\" (string, required) The voting key address. The private key does not have to be known by your wallet.\n "
590591 " It has to match the private key which is later used when voting on proposals.\n "
591- " If set to \" 0 \" or an empty string, the last on-chain voting key of the masternode will be used.\n "
592+ " If set to an empty string, the last on-chain voting key of the masternode will be used.\n "
592593 " 4. \" payoutAddress\" (string, required) The dash address to use for masternode reward payments\n "
593- " If set to \" 0 \" or an empty string, the last on-chain payout address of the masternode will be used.\n "
594+ " If set to an empty string, the last on-chain payout address of the masternode will be used.\n "
594595 " 5. \" feeSourceAddress\" (string, optional) If specified wallet will only use coins from this address to fund ProTx.\n "
595596 " If not specified, payoutAddress is the one that is going to be used.\n "
596597 " The private key belonging to this address must be known in your wallet.\n "
@@ -617,10 +618,10 @@ UniValue protx_update_registrar(const JSONRPCRequest& request)
617618 ptx.keyIDVoting = dmn->pdmnState ->keyIDVoting ;
618619 ptx.scriptPayout = dmn->pdmnState ->scriptPayout ;
619620
620- if (request.params [2 ].get_str () != " 0 " && request. params [ 2 ]. get_str () != " " ) {
621+ if (request.params [2 ].get_str () != " " ) {
621622 ptx.pubKeyOperator = ParseBLSPubKey (request.params [2 ].get_str (), " operator BLS address" );
622623 }
623- if (request.params [3 ].get_str () != " 0 " && request. params [ 3 ]. get_str () != " " ) {
624+ if (request.params [3 ].get_str () != " " ) {
624625 ptx.keyIDVoting = ParsePubKeyIDFromAddress (request.params [3 ].get_str (), " operator address" );
625626 }
626627
0 commit comments