From 1ac03f3f024193b8bb9826af51b4168a6a7dc1fa Mon Sep 17 00:00:00 2001 From: Methapon2001 <61303214+Methapon2001@users.noreply.github.com> Date: Wed, 3 Jul 2024 17:44:33 +0700 Subject: [PATCH] fix: error wrong cond --- src/controllers/customer-controller.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controllers/customer-controller.ts b/src/controllers/customer-controller.ts index 6b1d207..29571cc 100644 --- a/src/controllers/customer-controller.ts +++ b/src/controllers/customer-controller.ts @@ -441,7 +441,7 @@ export class CustomerController extends Controller { if ( customerBranch && - relation.find((a) => !customerBranch.find((b) => a.id !== b.id && a.branchNo === b.branchNo)) + relation.find((a) => customerBranch.find((b) => a.id !== b.id && a.branchNo === b.branchNo)) ) { throw new HttpError( HttpStatus.BAD_REQUEST,