@contrail/util
Advanced tools
Comparing version 1.0.8 to 1.0.9
export declare class ObjectUtil { | ||
static getByPath(obj: any, path: string, def?: string): any; | ||
static getByPath(obj: any, path: string, def?: any): any; | ||
static setByPath(obj: any, path: string, value: any): void; | ||
} |
@@ -11,5 +11,7 @@ "use strict"; | ||
pathUnits.forEach((level) => { | ||
obj = obj[level]; | ||
if (obj) { | ||
obj = obj[level]; | ||
} | ||
}); | ||
if (!obj || obj === undefined) { | ||
if (obj === undefined) { | ||
return def; | ||
@@ -16,0 +18,0 @@ } |
{ | ||
"name": "@contrail/util", | ||
"version": "1.0.8", | ||
"version": "1.0.9", | ||
"description": "General javascript utilities", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6416
12
153