Skip to content

Commit

Permalink
Change conditions for opening cancellation payments
Browse files Browse the repository at this point in the history
  • Loading branch information
danial303065 committed Aug 15, 2024
1 parent fc0bc98 commit 2f51725
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/relay/src/routers/PaymentRouter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1038,7 +1038,13 @@ export class PaymentRouter {
if (item === undefined) {
return res.status(200).json(ResponseMessage.getErrorMessage("2003"));
} else {
if (item.paymentStatus !== LoyaltyPaymentTaskStatus.CLOSED_NEW) {
if (
!(
item.paymentStatus === LoyaltyPaymentTaskStatus.CLOSED_NEW ||
item.paymentStatus === LoyaltyPaymentTaskStatus.DENIED_CANCEL ||
item.paymentStatus === LoyaltyPaymentTaskStatus.FAILED_CANCEL
)
) {
return res.status(200).json(ResponseMessage.getErrorMessage("2022"));
}

Expand Down

0 comments on commit 2f51725

Please sign in to comment.