mirror of
https://github.com/karl0ss/homepage.git
synced 2025-04-29 12:03:41 +01:00
Fix: add fallback for shvl syntax
This commit is contained in:
parent
0a50d5a6aa
commit
2cabe77b55
@ -18,7 +18,7 @@ function getValue(field, data) {
|
|||||||
|
|
||||||
// shvl is easier, everything else is kept for backwards compatibility.
|
// shvl is easier, everything else is kept for backwards compatibility.
|
||||||
if (typeof field === "string") {
|
if (typeof field === "string") {
|
||||||
return shvl.get(data, field, null);
|
return shvl.get(data, field, null) ?? data[field] ?? null;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (typeof lastField === "object") {
|
while (typeof lastField === "object") {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user