Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve readability of recent rate limiter changes.
This commit builds on the recent limiter updates. The recent changes introduced a new function named calcTxFee which could easily be confused with calculating the fees of the transaction rather than its intended purpose of calculating the minimum transaciton relay fee. Rather than taking that approach, this commit instead renames the existing function to calcMinRequiredTxRelayFee and uses a consistent variable name for the serialized size of a transaction. It then moves the check for whether or not the check should be applied based on the serialized size of the transcation and block priority to the call site. This approach also has the benefit of avoiding two calls to the calculation function since it's a local at the call site. ok @jrick, @dajohi
- Loading branch information
Showing
1 changed file
with
21 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters