Skip to content

Commit

Permalink
prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
dmosites committed Oct 2, 2023
1 parent e299fdf commit f3a605f
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions src/features/transactions/swapEventSubscriber.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@ import { BigNumber, Contract, Event as EthersEvent } from "ethers";
import { store } from "../../app/store";
import { notifyTransaction } from "../../components/Toasts/ToastController";
import { mineTransaction } from "./transactionActions";
import {
getSenderWalletForWrapperSwapLog,
} from "./transactionUtils";
import { getSenderWalletForWrapperSwapLog } from "./transactionUtils";
import { LastLookTransaction } from "./transactionsSlice";

export default function subscribeToSwapEvents(params: {
Expand All @@ -24,10 +22,18 @@ export default function subscribeToSwapEvents(params: {
const _account = account.toLowerCase();
const wrapperAddress = Wrapper.getAddress(chainId) || "";

const onSwap = async (nonce: BigNumber, signerWallet: string, swapEvent: EthersEvent) => {
const fullArgs = await getFullSwapERC20({
nonce: nonce.toString(), signerWallet
}, await swapEvent.getTransaction())
const onSwap = async (
nonce: BigNumber,
signerWallet: string,
swapEvent: EthersEvent
) => {
const fullArgs = await getFullSwapERC20(
{
nonce: nonce.toString(),
signerWallet,
},
await swapEvent.getTransaction()
);

if (
fullArgs.senderWallet.toLowerCase() !== _account &&
Expand Down

0 comments on commit f3a605f

Please sign in to comment.