diff --git a/src/components/bounty/BountyInfo.tsx b/src/components/bounty/BountyInfo.tsx index b6a7530..194f66e 100644 --- a/src/components/bounty/BountyInfo.tsx +++ b/src/components/bounty/BountyInfo.tsx @@ -39,6 +39,12 @@ export default function BountyInfo({ bountyId }: { bountyId: string }) { const signMutation = useMutation({ mutationFn: async (bountyId: string) => { + //arbitrum has a problem with message signing, so all confirmations are on base + const chainId = await account.connector?.getChainId(); + if (chainId !== 8453) { + await switctChain.switchChainAsync({ chainId: 8453 }); + } + const message = getBanSignatureFirstLine({ id: Number(bountyId), diff --git a/src/components/bounty/ClaimItem.tsx b/src/components/bounty/ClaimItem.tsx index 8feb5d3..6b1a297 100644 --- a/src/components/bounty/ClaimItem.tsx +++ b/src/components/bounty/ClaimItem.tsx @@ -47,6 +47,11 @@ export default function ClaimItem({ const signMutation = useMutation({ mutationFn: async (claimId: string) => { + const chainId = await account.connector?.getChainId(); + if (chainId !== 8453) { + //arbitrum has a problem with message signing, so all confirmations are on base + await switctChain.switchChainAsync({ chainId: 8453 }); + } const message = getBanSignatureFirstLine({ id: Number(claimId), chainId: chain.id, diff --git a/src/trpc/routers/_app.ts b/src/trpc/routers/_app.ts index 9bee49f..55c4621 100644 --- a/src/trpc/routers/_app.ts +++ b/src/trpc/routers/_app.ts @@ -527,7 +527,7 @@ export const appRouter = createTRPCRouter({ } const isAdmin = checkIsAdmin(input.address); - const chain = chains[input.chainName]; + const chain = chains['base']; if (!isAdmin) { throw new TRPCError({