From f8186cb2ea94a56234d1ebb146bfd270f956264d Mon Sep 17 00:00:00 2001 From: "k.triantafyllou" Date: Mon, 3 Jun 2024 15:59:25 +0300 Subject: [PATCH] [develop]: Fix check in belongsTo class. --- utils/entities/resultLandingInfo.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/entities/resultLandingInfo.ts b/utils/entities/resultLandingInfo.ts index 453c8297..8097da49 100644 --- a/utils/entities/resultLandingInfo.ts +++ b/utils/entities/resultLandingInfo.ts @@ -70,7 +70,7 @@ export class BelongsTo { if (field) { field = Object.assign({}, field); let json: any = element; - if (field.path.length > 0) { + if (field.path.length > 0 && json) { if (Array.isArray(json)) { return json.findIndex(value => BelongsTo.check(value, field)) != -1; } else {