Skip to content

Commit

Permalink
fix: aa flow only for atomicBatch
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeday committed Dec 12, 2024
1 parent 0463176 commit 75f1a0f
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions modules/web3/hooks/use-aa.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,11 @@ export const useAA = () => {
const capabilities =
capabilitiesQuery.data && capabilitiesQuery.data[chainId];

const isAA = !!capabilities;
// use new AA flow only for batching supported accounts
// because some wallets cannot handle non-atomic batching (e.g Ambire EOA)
const isAA = !!capabilities?.atomicBatch?.supported;

const areAuxiliaryFundsSupported = !!(
capabilities?.auxiliaryFunds &&
capabilities.auxiliaryFunds.supported === true
);
const areAuxiliaryFundsSupported = !!capabilities?.auxiliaryFunds?.supported;

return {
...capabilitiesQuery,
Expand Down

0 comments on commit 75f1a0f

Please sign in to comment.