Skip to content

Commit

Permalink
Fix re-submit invoice
Browse files Browse the repository at this point in the history
  • Loading branch information
Reckless-Satoshi committed May 2, 2024
1 parent e8283f2 commit 7454ee8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions api/logics.py
Original file line number Diff line number Diff line change
Expand Up @@ -910,6 +910,12 @@ def update_invoice(cls, order, user, invoice, routing_budget_ppm):
return False, payout["context"]

if order.payout:
order.payout.concept = LNPayment.Concepts.PAYBUYER
order.payout.type = LNPayment.Types.NORM
order.payout.sender = User.objects.get(username=ESCROW_USERNAME)
order.payout.receiver = (user,)
order.payout.routing_budget_ppm = (routing_budget_ppm,)
order.payout.routing_budget_sats = (routing_budget_sats,)
order.payout.invoice = invoice
order.payout.status = LNPayment.Status.VALIDI
order.payout.num_satoshis = num_satoshis
Expand Down

0 comments on commit 7454ee8

Please sign in to comment.