From ec51fa233a6df5f62e83e4f94d276e0a62a6e034 Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Thu, 9 Nov 2023 12:41:15 -0500 Subject: [PATCH] Document an accepted false positive --- processor/src/multisigs/mod.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/processor/src/multisigs/mod.rs b/processor/src/multisigs/mod.rs index 6315ef5b..20d2bce1 100644 --- a/processor/src/multisigs/mod.rs +++ b/processor/src/multisigs/mod.rs @@ -728,6 +728,9 @@ impl MultisigManager { running_operating_costs, ); + // This will false positive on a transaction being refunded which meets these conditions + // That doesn't impact any of the following code at this time yet shows consideration + // is needed here in the future let to_be_forwarded = { let output = &plan.inputs[0]; (step == RotationStep::ForwardFromExisting) && @@ -749,7 +752,7 @@ impl MultisigManager { // Restore running_operating_costs to operating_costs if to_be_forwarded { - // If we're forwarding this output, operating_costs should still be 0 + // If we're forwarding (or refunding) this output, operating_costs should still be 0 // Either this TX wasn't created, causing no operating costs, or it was yet it'd be // amortized assert_eq!(operating_costs, 0);