slippage stuff

This commit is contained in:
2025-10-14 18:26:36 -04:00
parent 63a96b9cf1
commit 64b998d119
2 changed files with 63 additions and 2 deletions

View File

@@ -33,7 +33,7 @@ export function useGetAllTokens(offset: number = 0, limit: number = 100) {
// Get chain ID and contract address
const chainId = await publicClient.getChainId();
const address = chainInfo[chainId.toString()]?.IPartyPlanner;
const address = (chainInfo as Record<string, { IPartyPlanner: string; IPartyPoolViewer: string }>)[chainId.toString()]?.IPartyPlanner;
if (!address) {
setError('IPartyPlanner contract not found for current chain');
@@ -43,7 +43,7 @@ export function useGetAllTokens(offset: number = 0, limit: number = 100) {
// Call getAllTokens function
const result = await publicClient.readContract({
address,
address: address as `0x${string}`,
abi: IPartyPlannerABI,
functionName: 'getAllTokens',
args: [BigInt(offset), BigInt(limit)],