mirror of
https://github.com/aljazceru/plugins.git
synced 2026-01-31 10:24:22 +01:00
drain: fix receivable and 3ksat margin workaround
This commit is contained in:
committed by
Christian Decker
parent
eaee585f16
commit
6f0380bdfb
@@ -97,7 +97,10 @@ def spendable_from_scid(plugin, payload, scid=None):
|
|||||||
their_reserve = their
|
their_reserve = their
|
||||||
|
|
||||||
spendable = channel_peer['spendable_msat']
|
spendable = channel_peer['spendable_msat']
|
||||||
receivable = their - their_reserve
|
receivable = channel_peer['receivable_msat']
|
||||||
|
if not receivable:
|
||||||
|
# receivable_msat was added with the 0.8.2 release, have a fallback
|
||||||
|
receivable = their - their_reserve - Millisatoshi('3000sat')
|
||||||
return spendable, receivable
|
return spendable, receivable
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user