No change in behavior. Get rid of specifiedConfirmTarget if/else block and
rename specifiedConfirmTarget and ignoreUserSetFee variables to
ignoreGlobalPayTxFee.
throwJSONRPCError(RPC_INVALID_PARAMETER,"confTarget and totalFee options should not both be set. Please provide either a confirmation target for fee estimation or an explicit total fee for the transaction.");
throwJSONRPCError(RPC_INVALID_PARAMETER,"confTarget and totalFee options should not both be set. Please provide either a confirmation target for fee estimation or an explicit total fee for the transaction.");
}elseif(options.exists("confTarget")){
}elseif(options.exists("confTarget")){
specifiedConfirmTarget=true;
// If the user has explicitly set a confTarget in this rpc call,
// then override the default logic that uses the global payTxFee
// instead of the confirmation target.
ignoreGlobalPayTxFee=true;
newConfirmTarget=options["confTarget"].get_int();
newConfirmTarget=options["confTarget"].get_int();
if(newConfirmTarget<=0){// upper-bound will be checked by estimatefee/smartfee
if(newConfirmTarget<=0){// upper-bound will be checked by estimatefee/smartfee
throwJSONRPCError(RPC_INVALID_PARAMETER,"Invalid confTarget (cannot be <= 0)");
throwJSONRPCError(RPC_INVALID_PARAMETER,"Invalid confTarget (cannot be <= 0)");