mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-17 13:07:54 +02:00
Merge 3b5fb6e77a into merged_master (Bitcoin PR bitcoin/bitcoin#26213)
This commit is contained in:
commit
5baaf035fa
5 changed files with 16 additions and 10 deletions
|
|
@ -731,9 +731,7 @@ static RPCHelpMan setban()
|
|||
if (!request.params[2].isNull())
|
||||
banTime = request.params[2].getInt<int64_t>();
|
||||
|
||||
bool absolute = false;
|
||||
if (request.params[3].isTrue())
|
||||
absolute = true;
|
||||
const bool absolute{request.params[3].isNull() ? false : request.params[3].get_bool()};
|
||||
|
||||
if (isSubnet) {
|
||||
node.banman->Ban(subNet, banTime, absolute);
|
||||
|
|
@ -942,7 +940,7 @@ static RPCHelpMan addpeeraddress()
|
|||
|
||||
const std::string& addr_string{request.params[0].get_str()};
|
||||
const auto port{request.params[1].getInt<uint16_t>()};
|
||||
const bool tried{request.params[2].isTrue()};
|
||||
const bool tried{request.params[2].isNull() ? false : request.params[2].get_bool()};
|
||||
|
||||
UniValue obj(UniValue::VOBJ);
|
||||
CNetAddr net_addr;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue