updated throw

This commit is contained in:
Warunee Tamkoo 2024-06-12 13:23:02 +07:00
parent aaf28beb3c
commit 624b1a0627

View file

@ -28,9 +28,9 @@ export class AuthSysController extends Controller {
@Get("list") @Get("list")
public async listAuthSys() { public async listAuthSys() {
const getList = await this.authSysRepo.find(); const getList = await this.authSysRepo.find();
// if (!getList || getList.length === 0) { if (!getList || getList.length === 0) {
// throw new HttpError(HttpStatus.NOT_FOUND, "ไม่พบข้อมูล"); throw new HttpError(HttpStatus.NOT_FOUND, "ไม่พบข้อมูล");
// } }
return new HttpSuccess(getList); return new HttpSuccess(getList);
} }