From a5c662b0b5850ed9affb4c68ad16b1040ec62223 Mon Sep 17 00:00:00 2001 From: Christophe Date: Mon, 15 Jul 2024 15:55:01 +0000 Subject: [PATCH] Enforce upgradeExecutor parameter --- src/actions/hasRole.ts | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/actions/hasRole.ts b/src/actions/hasRole.ts index c6f5a8a9..b96b1af6 100644 --- a/src/actions/hasRole.ts +++ b/src/actions/hasRole.ts @@ -1,18 +1,13 @@ import { Address, Chain, PublicClient, ReadContractReturnType, Transport } from 'viem'; import { upgradeExecutor } from '../contracts'; -import { ActionParameters } from '../types/Actions'; import { UpgradeExecutorRole } from '../upgradeExecutorEncodeFunctionData'; -type Args = { +type UpgradeExecutorABI = typeof upgradeExecutor.abi; +export type HasRoleParameters = { + upgradeExecutor: Address; role: UpgradeExecutorRole; address: Address; }; -type UpgradeExecutorABI = typeof upgradeExecutor.abi; -export type HasRoleParameters = ActionParameters< - Args, - 'upgradeExecutor', - Curried ->; export type HasRoleReturnType = ReadContractReturnType;