Skip to content

Commit

Permalink
chore(backend): swap incoming payment receiver checks
Browse files Browse the repository at this point in the history
  • Loading branch information
wilsonianb committed Sep 22, 2022
1 parent 6c74f20 commit 0522bac
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/backend/src/open_payments/client/service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ export class Receiver extends ConnectionBase {
if (incomingPayment.completed) {
return undefined
}
if (typeof incomingPayment.ilpStreamConnection !== 'object') {
return undefined
}
if (
incomingPayment.expiresAt &&
new Date(incomingPayment.expiresAt).getTime() <= Date.now()
) {
return undefined
}
if (typeof incomingPayment.ilpStreamConnection !== 'object') {
return undefined
}
const receivedAmount = parseAmount(incomingPayment.receivedAmount)
const incomingAmount = incomingPayment.incomingAmount
? parseAmount(incomingPayment.incomingAmount)
Expand Down

0 comments on commit 0522bac

Please sign in to comment.