Skip to content

Commit

Permalink
reduce cognitive load
Browse files Browse the repository at this point in the history
  • Loading branch information
dbauszus-glx committed Jan 9, 2025
1 parent 5c3fdde commit 4df1a7c
Showing 1 changed file with 11 additions and 12 deletions.
23 changes: 11 additions & 12 deletions lib/utils/jsonParser.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -109,19 +109,18 @@ function excludeProperty(value) {
return true;
}

if (value instanceof Object) {
if (
value.type === 'html' &&
Array.isArray(value.template) &&
Array.isArray(value.values)
) {
return true;
}
if (
value instanceof Object &&
value.type === 'html' &&
Array.isArray(value.template) &&
Array.isArray(value.values)
) {
return true;
}

// Openlayer objects will have an unique id.
if (Object.hasOwn(value, 'ol_uid')) {
return true;
}
// Openlayer objects will have an unique id.
if (value instanceof Object && Object.hasOwn(value, 'ol_uid')) {
return true;
}

if (Array.isArray(value)) {
Expand Down

0 comments on commit 4df1a7c

Please sign in to comment.