From 4bb3b257b1307da33c8e5e29f6adbf0b57636be1 Mon Sep 17 00:00:00 2001 From: koekiebox Date: Sun, 24 Nov 2024 12:49:07 +0100 Subject: [PATCH] feat(2981): fix caching misplacement. --- packages/backend/src/open_payments/payment/outgoing/service.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/backend/src/open_payments/payment/outgoing/service.ts b/packages/backend/src/open_payments/payment/outgoing/service.ts index b09c705664..9cbf79f03f 100644 --- a/packages/backend/src/open_payments/payment/outgoing/service.ts +++ b/packages/backend/src/open_payments/payment/outgoing/service.ts @@ -617,12 +617,13 @@ async function fundPayment( .forUpdate() .withGraphFetched('quote') if (!payment) return FundingError.UnknownPayment + + await deps.assetService.setOn(payment.quote) if (payment.state !== OutgoingPaymentState.Funding) { return FundingError.WrongState } if (amount !== payment.debitAmount.value) return FundingError.InvalidAmount - await deps.assetService.setOn(payment.quote) // Create the outgoing payment liquidity account before trying to transfer funds to it. try { await deps.accountingService.createLiquidityAccount(