mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-12 12:52:35 -03:00
refactor: rename local gArgs to args
Avoid confusion with the global gArgs
This commit is contained in:
parent
bd74004532
commit
cba749a9b7
1 changed files with 4 additions and 4 deletions
|
@ -74,13 +74,13 @@ BlockAssembler::BlockAssembler(Chainstate& chainstate, const CTxMemPool* mempool
|
||||||
nBlockMaxWeight = std::max<size_t>(4000, std::min<size_t>(MAX_BLOCK_WEIGHT - 4000, options.nBlockMaxWeight));
|
nBlockMaxWeight = std::max<size_t>(4000, std::min<size_t>(MAX_BLOCK_WEIGHT - 4000, options.nBlockMaxWeight));
|
||||||
}
|
}
|
||||||
|
|
||||||
void ApplyArgsManOptions(const ArgsManager& gArgs, BlockAssembler::Options& options)
|
void ApplyArgsManOptions(const ArgsManager& args, BlockAssembler::Options& options)
|
||||||
{
|
{
|
||||||
// Block resource limits
|
// Block resource limits
|
||||||
// If -blockmaxweight is not given, limit to DEFAULT_BLOCK_MAX_WEIGHT
|
// If -blockmaxweight is not given, limit to DEFAULT_BLOCK_MAX_WEIGHT
|
||||||
options.nBlockMaxWeight = gArgs.GetIntArg("-blockmaxweight", DEFAULT_BLOCK_MAX_WEIGHT);
|
options.nBlockMaxWeight = args.GetIntArg("-blockmaxweight", DEFAULT_BLOCK_MAX_WEIGHT);
|
||||||
if (gArgs.IsArgSet("-blockmintxfee")) {
|
if (args.IsArgSet("-blockmintxfee")) {
|
||||||
std::optional<CAmount> parsed = ParseMoney(gArgs.GetArg("-blockmintxfee", ""));
|
std::optional<CAmount> parsed = ParseMoney(args.GetArg("-blockmintxfee", ""));
|
||||||
options.blockMinFeeRate = CFeeRate{parsed.value_or(DEFAULT_BLOCK_MIN_TX_FEE)};
|
options.blockMinFeeRate = CFeeRate{parsed.value_or(DEFAULT_BLOCK_MIN_TX_FEE)};
|
||||||
} else {
|
} else {
|
||||||
options.blockMinFeeRate = CFeeRate{DEFAULT_BLOCK_MIN_TX_FEE};
|
options.blockMinFeeRate = CFeeRate{DEFAULT_BLOCK_MIN_TX_FEE};
|
||||||
|
|
Loading…
Reference in a new issue