mirror of
https://github.com/nasa/openmct.git
synced 2025-02-21 01:42:31 +00:00
Fix importing from JSON file where some property values are null (#3813)
This commit is contained in:
parent
721bdd737a
commit
8157cdc7e9
@ -154,7 +154,9 @@ define(['zepto', 'objectUtils'], function ($, objectUtils) {
|
||||
tree = JSON.stringify(tree).replace(new RegExp(oldIdKeyString, 'g'), newIdKeyString);
|
||||
|
||||
return JSON.parse(tree, (key, value) => {
|
||||
if (Object.prototype.hasOwnProperty.call(value, 'key')
|
||||
if (value !== undefined
|
||||
&& value !== null
|
||||
&& Object.prototype.hasOwnProperty.call(value, 'key')
|
||||
&& Object.prototype.hasOwnProperty.call(value, 'namespace')
|
||||
&& value.key === oldId.key
|
||||
&& value.namespace === oldId.namespace) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user