Skip to content

Commit fdb8de8

Browse files
committed
Derive FundingContribution::net_value implicitly
This commit removes `FundingContribution::value_added` as tracking it is unnecessary -- it can just be derived from the total amount in minus total amount out minus fees. Doing so also highlighted that there was an incorrect assumption in how feerates are computed/adjusted. Ultimately, we don't care whether a contribution has inputs or not. Instead, we look at whether it's contributing a positive or negative amount to the channel, and enforce different constraints for each.
1 parent da6549d commit fdb8de8

2 files changed

Lines changed: 259 additions & 452 deletions

File tree

0 commit comments

Comments
 (0)