Enhancement: support shvl syntax for customapi fields (#5020)

This commit is contained in:
shamoon
2025-03-17 11:47:55 -07:00
committed by GitHub
parent 8d20f22932
commit dca23e8547
2 changed files with 18 additions and 15 deletions

View File

@@ -16,6 +16,11 @@ function getValue(field, data) {
return value;
}
// shvl is easier, everything else is kept for backwards compatibility.
if (typeof field === "string") {
return shvl.get(data, field, null);
}
while (typeof lastField === "object") {
key = Object.keys(lastField)[0] ?? null;