Skip to content

Commit

Permalink
fix: fully resolve receipt download url
Browse files Browse the repository at this point in the history
  • Loading branch information
KenLSM committed Feb 2, 2024
1 parent 922b6f6 commit f18680e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/app/modules/payments/payment.service.utils.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import config from 'src/app/config/config'
import { IPaymentSchema } from 'src/types'

import { centsToDollars } from '../../../../shared/utils/payments'
Expand All @@ -8,7 +9,10 @@ export const getPaymentFields = (payment: IPaymentSchema) => {
type: 'payment_charge',
status: payment.status,
payer: payment.email,
url: getPaymentInvoiceDownloadUrlPath(payment.formId, payment._id),
url: `${config.app.appUrl}/api/v3/${getPaymentInvoiceDownloadUrlPath(
payment.formId,
payment._id,
)}`,
paymentIntent: payment.paymentIntentId,
amount: centsToDollars(payment.amount),
productService:
Expand Down

0 comments on commit f18680e

Please sign in to comment.