Skip to content

Commit

Permalink
[lib] Fix SIWESignatureRequestData union type
Browse files Browse the repository at this point in the history
Discussed this today in a meeting with Kamil and Tomek. `{ messageType: 'msg_backup_restore' }` should not be a valid type without the other properties.
  • Loading branch information
Ashoat committed Jan 7, 2025
1 parent c9dcc62 commit 3932e8c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/types/siwe-types.js
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ export const SIWEMessageTypes = Object.freeze({
export type SIWEMessageType = $Values<typeof SIWEMessageTypes>;

export type SIWESignatureRequestData =
| { +messageType: SIWEMessageType }
| { +messageType: 'msg_auth' | 'msg_backup' }
| {
+messageType: 'msg_backup_restore',
+siweNonce: string,
Expand Down

0 comments on commit 3932e8c

Please sign in to comment.