Skip to content

Commit 68ebdde

Browse files
committed
refactor: remove fee argument from TransactionResult::success_with_soft_limit, #5900
1 parent 157cf37 commit 68ebdde

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

stackslib/src/chainstate/nakamoto/miner.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -737,7 +737,7 @@ impl BlockBuilder for NakamotoBlockBuilder {
737737
}
738738

739739
let cost_before = clarity_tx.cost_so_far();
740-
let (fee, receipt) =
740+
let (_fee, receipt) =
741741
match StacksChainState::process_transaction(clarity_tx, tx, quiet, ast_rules) {
742742
Ok(x) => x,
743743
Err(e) => {
@@ -764,7 +764,7 @@ impl BlockBuilder for NakamotoBlockBuilder {
764764

765765
// save
766766
self.txs.push(tx.clone());
767-
TransactionResult::success_with_soft_limit(tx, fee, receipt, soft_limit_reached)
767+
TransactionResult::success_with_soft_limit(tx, receipt, soft_limit_reached)
768768
};
769769

770770
self.bytes_so_far += tx_len;

stackslib/src/chainstate/stacks/miner.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -478,14 +478,13 @@ impl TransactionResult {
478478
/// This method logs "transaction success" as a side effect.
479479
pub fn success_with_soft_limit(
480480
transaction: &StacksTransaction,
481-
fee: u64,
482481
receipt: StacksTransactionReceipt,
483482
soft_limit_reached: bool,
484483
) -> TransactionResult {
485484
Self::log_transaction_success(transaction);
486485
Self::Success(TransactionSuccess {
487486
tx: transaction.clone(),
488-
fee,
487+
fee: transaction.get_tx_fee(),
489488
receipt,
490489
soft_limit_reached,
491490
})

0 commit comments

Comments
 (0)