We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent aa029fe commit 4dd7112Copy full SHA for 4dd7112
1 file changed
packages/siop-oid4vp/lib/authorization-response/Payload.ts
@@ -44,11 +44,9 @@ const normalizeToArray = (
44
if (Array.isArray(value)) {
45
presentationsArray = value
46
} else if (isArrayLikeObject(value)) {
47
- // Convert array-like object to array by sorting keys numerically
48
const sortedKeys = Object.keys(value).sort((a, b) => Number(a) - Number(b))
49
presentationsArray = sortedKeys.map(key => value[key])
50
} else {
51
- // Single value, wrap in array
52
presentationsArray = [value]
53
}
54
@@ -58,7 +56,6 @@ const normalizeToArray = (
58
56
)
59
57
60
61
- // Cast to NonEmptyArray since we verified length > 0
62
return presentationsArray as NonEmptyArray<DcqlPresentationEntry>
63
64
0 commit comments