fix: wrong condition check
This commit is contained in:
parent
1c04e475b6
commit
e44f563e35
1 changed files with 2 additions and 2 deletions
|
|
@ -391,7 +391,7 @@ export class CustomerBranchController extends Controller {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (!affilationBranch || !affilationHeadBranch) {
|
if (!affilationBranch && !affilationHeadBranch) {
|
||||||
throw new HttpError(
|
throw new HttpError(
|
||||||
HttpStatus.FORBIDDEN,
|
HttpStatus.FORBIDDEN,
|
||||||
"You do not have permission to perform this action.",
|
"You do not have permission to perform this action.",
|
||||||
|
|
@ -544,7 +544,7 @@ export class CustomerBranchController extends Controller {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (!affilationBranch || !affilationHeadBranch) {
|
if (!affilationBranch && !affilationHeadBranch) {
|
||||||
throw new HttpError(
|
throw new HttpError(
|
||||||
HttpStatus.FORBIDDEN,
|
HttpStatus.FORBIDDEN,
|
||||||
"You do not have permission to perform this action.",
|
"You do not have permission to perform this action.",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue