Add permissioned payouts mode debugging envvar

This commit is contained in:
Reckless_Satoshi 2023-04-25 03:13:28 -07:00
parent 8c81bed013
commit b9aaf9f1bc
No known key found for this signature in database
GPG Key ID: 9C4585B561315571
2 changed files with 4 additions and 0 deletions

View File

@ -117,6 +117,7 @@ MIN_FLAT_ROUTING_FEE_LIMIT_REWARD = 2
# Routing timeouts
REWARDS_TIMEOUT_SECONDS = 30
PAYOUT_TIMEOUT_SECONDS = 90
DEBUG_PERMISSIONED_PAYOUTS = False
# REVERSE SUBMARINE SWAP PAYOUTS
# Disable on-the-fly swaps feature

View File

@ -84,6 +84,9 @@ def follow_send_payment(hash):
from api.lightning.node import LNNode
from api.models import LNPayment
if config("DEBUG_PERMISSIONED_PAYOUTS", cast=bool, default=False):
return
lnpayment = LNPayment.objects.get(payment_hash=hash)
lnpayment.last_routing_time = timezone.now()
lnpayment.save()