From a08dd2800d2cd23c14fa210e495a1cbfa2e9b191 Mon Sep 17 00:00:00 2001 From: tophf Date: Mon, 30 Aug 2021 21:15:44 +0300 Subject: [PATCH] fix objectDiff --- manage/events.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manage/events.js b/manage/events.js index e438ff11..282cc1ba 100644 --- a/manage/events.js +++ b/manage/events.js @@ -269,7 +269,7 @@ function objectDiff(first, second, path = '') { ) { diff.push({path, key, values: [a, b], type: 'changed'}); } - } else if (typeof a === 'object' && typeof b === 'object') { + } else if (a && b && typeof a === 'object' && typeof b === 'object') { diff.push(...objectDiff(a, b, path + key + '.')); } else { diff.push({path, key, values: [a, b], type: 'changed'});