Skip to content

Commit b1f366f

Browse files
fix: Correct validation for assets scopes (#3039)
Fixes a typo in the validation for `endowment:assets`, that accidentally expected a nested array of scopes. --------- Co-authored-by: Maarten Zuidhoorn <[email protected]>
1 parent b9066f7 commit b1f366f

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

packages/snaps-utils/src/manifest/validation.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -189,10 +189,7 @@ export const EmptyObjectStruct = object<EmptyObject>({}) as unknown as Struct<
189189
/* eslint-disable @typescript-eslint/naming-convention */
190190
export const PermissionsStruct: Describe<InitialPermissions> = type({
191191
'endowment:assets': optional(
192-
mergeStructs(
193-
HandlerCaveatsStruct,
194-
object({ scopes: size(array(ChainIdsStruct), 1, Infinity) }),
195-
),
192+
mergeStructs(HandlerCaveatsStruct, object({ scopes: ChainIdsStruct })),
196193
),
197194
'endowment:cronjob': optional(
198195
mergeStructs(

0 commit comments

Comments
 (0)