From a834beb4bc0bb42f2f21b50f1cbb5a961e938b1e Mon Sep 17 00:00:00 2001 From: khanti42 Date: Wed, 23 Oct 2024 09:01:31 +0200 Subject: [PATCH] chore: fix missing access to requestParams in call to revamped rpc (#401) --- packages/starknet-snap/src/index.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/starknet-snap/src/index.ts b/packages/starknet-snap/src/index.ts index 6c71914b..a33e66c9 100644 --- a/packages/starknet-snap/src/index.ts +++ b/packages/starknet-snap/src/index.ts @@ -185,7 +185,7 @@ export const onRpcRequest: OnRpcRequestHandler = async ({ request }) => { case 'starkNet_signDeclareTransaction': return await signDeclareTransaction.execute( - apiParams as unknown as SignDeclareTransactionParams, + apiParams.requestParams as unknown as SignDeclareTransactionParams, ); case 'starkNet_signDeployAccountTransaction': @@ -196,7 +196,7 @@ export const onRpcRequest: OnRpcRequestHandler = async ({ request }) => { case 'starkNet_verifySignedMessage': return await verifySignature.execute( - apiParams as unknown as VerifySignatureParams, + apiParams.requestParams as unknown as VerifySignatureParams, ); case 'starkNet_getErc20TokenBalance': @@ -278,7 +278,7 @@ export const onRpcRequest: OnRpcRequestHandler = async ({ request }) => { case 'starkNet_declareContract': return await declareContract.execute( - apiParams as unknown as DeclareContractParams, + apiParams.requestParams as unknown as DeclareContractParams, ); case 'starkNet_getStarkName': @@ -286,7 +286,7 @@ export const onRpcRequest: OnRpcRequestHandler = async ({ request }) => { case 'starkNet_getDeploymentData': return await getDeploymentData.execute( - apiParams as unknown as GetDeploymentDataParams, + apiParams.requestParams as unknown as GetDeploymentDataParams, ); default: