diff --git a/src/controllers/KpiReasonController.ts b/src/controllers/KpiReasonController.ts index 0c34e40..e3f156c 100644 --- a/src/controllers/KpiReasonController.ts +++ b/src/controllers/KpiReasonController.ts @@ -75,8 +75,9 @@ export class kpiReasonController extends Controller { if (user.trim().toUpperCase() == "USER") { const kpiUserEvaluation = await this.kpiUserPlan.findOne({ where: { id: id }, - relations: ["kpiUserEvaluation", "kpiUserEvaluation.evaluatorId"], + relations: ["kpiUserEvaluation"], }); + if (!kpiUserEvaluation) { throw new HttpError( HttpStatusCode.NOT_FOUND,