Skip to content

Commit

Permalink
show error notifaction in useTransactor + throw it forward
Browse files Browse the repository at this point in the history
  • Loading branch information
technophile-04 committed Mar 7, 2024
1 parent b09300f commit b036b23
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/nextjs/hooks/scaffold-eth/useTransactor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,8 @@ export const useTransactor = (_walletClient?: WalletClient): TransactionFunc =>
}
console.error("⚡️ ~ file: useTransactor.ts ~ error", error);
const message = getParsedError(error);
throw new Error(message);
notification.error(message);
throw error;
}

return transactionHash;
Expand Down

0 comments on commit b036b23

Please sign in to comment.