lnwallet: calcStaticFee now directly uses feePerKw

This commit is contained in:
Olaoluwa Osuntokun committed 2017-05-16 18:56:46 -07:00
1 parent 52942e4f13
commit 222385bf73
2 files changed
+4 -4

No files matched your search

+2 -2
View File
@@ -337,9 +337,9 @@ func calcStaticFee(numHTLCs int) btcutil.Amount {
const (
commitWeight = btcutil.Amount(724)
htlcWeight = 172
feePerByte = btcutil.Amount(50 * 4)
feePerKw = btcutil.Amount(24/4) * 1000
)
return feePerByte * (commitWeight +
return feePerKw * (commitWeight +
btcutil.Amount(htlcWeight*numHTLCs)) / 1000
}
+2 -2
View File
@@ -109,9 +109,9 @@ func calcStaticFee(numHTLCs int) btcutil.Amount {
const (
commitWeight = btcutil.Amount(724)
htlcWeight = 172
feePerByte = btcutil.Amount(250 * 4)
feePerKw = btcutil.Amount(250/4) * 1000
)
return feePerByte * (commitWeight +
return feePerKw * (commitWeight +
btcutil.Amount(htlcWeight*numHTLCs)) / 1000
}