File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -52,15 +52,16 @@ export async function getAwsKmsAccount(
5252
5353 const r = `0x${ signature . r . toString ( "hex" ) } ` as Hex ;
5454 const s = `0x${ signature . s . toString ( "hex" ) } ` as Hex ;
55- const v = signature . v ;
55+ const v = BigInt ( signature . v ) ;
5656
57- const yParity = v % 2 === 0 ? 1 : ( 0 as 0 | 1 ) ;
57+ const yParity : 0 | 1 = signature . v % 2 === 0 ? 1 : 0 ;
5858
5959 const signedTx = serializeTransaction ( {
6060 transaction : tx ,
6161 signature : {
6262 r,
6363 s,
64+ v,
6465 yParity,
6566 } ,
6667 } ) ;
Original file line number Diff line number Diff line change @@ -72,15 +72,16 @@ export async function getGcpKmsAccount(
7272
7373 const r = signature . r . toString ( ) as Hex ;
7474 const s = signature . s . toString ( ) as Hex ;
75- const v = signature . v ;
75+ const v = BigInt ( signature . v ) ;
7676
77- const yParity = v % 2 === 0 ? 1 : ( 0 as 0 | 1 ) ;
77+ const yParity : 0 | 1 = signature . v % 2 === 0 ? 1 : 0 ;
7878
7979 const signedTx = serializeTransaction ( {
8080 transaction : tx ,
8181 signature : {
8282 r,
8383 s,
84+ v,
8485 yParity,
8586 } ,
8687 } ) ;
You can’t perform that action at this time.
0 commit comments