mirror of
https://github.com/dadosfera/maestro.git
synced 2026-11-15 18:49:07 +00:00
FIX: fixed condition of getObjValueFromPath
This commit is contained in:
@@ -4,7 +4,7 @@ export function getObjValueFromPath<T>(data: { object: T; path: string }): T {
|
||||
|
||||
let value = JSON.parse(JSON.stringify(object));
|
||||
for (const key of keys) {
|
||||
if (value) value = value[key];
|
||||
if (value != undefined) value = value[key];
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user