Skip to content

Commit 4b82a66

Browse files
author
Vishal Shingala
committed
Replaced Object.hasOwnProperty usages with loadsh _.has for safe access
1 parent b96c4e9 commit 4b82a66

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/31XUtils/schemaUtils31X.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ module.exports = {
154154
const resolvedSchema = _.cloneDeep(refSchema),
155155
outerKeys = Object.keys(outerProps);
156156
outerKeys.forEach((key) => {
157-
if (_.has(resolvedSchema, key)) {
157+
if (_.isObject(resolvedSchema) && _.isObject(outerProps)) {
158158
resolvedSchema[key] = (resolvedSchema[key] && Array.isArray(resolvedSchema[key])) ?
159159
[...new Set([...resolvedSchema[key], ...outerProps[key]])] :
160160
outerProps[key];

0 commit comments

Comments
 (0)