From e849c1cfdbfd9011b57f4809146199e15cc33fc0 Mon Sep 17 00:00:00 2001 From: Fadli Date: Sun, 21 Aug 2022 00:37:19 +0700 Subject: [PATCH] - fix when all the product is not active --- src/transaction/transaction.service.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/transaction/transaction.service.ts b/src/transaction/transaction.service.ts index be86fb7..bdf7273 100644 --- a/src/transaction/transaction.service.ts +++ b/src/transaction/transaction.service.ts @@ -310,7 +310,7 @@ export class TransactionService { 'prepaid', ); - if (productData.status == 'NOT ACTIVE') { + if (!productData.status.includes('ACTIVE')) { throw new HttpException( { statusCode: HttpStatus.INTERNAL_SERVER_ERROR, @@ -467,7 +467,7 @@ export class TransactionService { 'prepaid', ); - if (productData.status == 'NOT ACTIVE') { + if (!productData.status.includes('ACTIVE')) { throw new HttpException( { statusCode: HttpStatus.INTERNAL_SERVER_ERROR,