Skip to content

Commit afcc69c

Browse files
committed
fix edge case bug with cow amm transaction stepper
1 parent a9e089c commit afcc69c

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

packages/nextjs/hooks/cow/useFinalizePoolTxHash.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export function useFinalizePoolTxHash() {
3131

3232
if (txReceipt.status === "success") {
3333
if (!poolCreation?.step) throw new Error("Missing pool creation step");
34-
updatePoolCreation({ finalizePoolTx: { safeHash, wagmiHash, isSuccess: true }, step: poolCreation.step + 1 });
34+
updatePoolCreation({ finalizePoolTx: { safeHash, wagmiHash, isSuccess: true }, step: 8 });
3535
return { isSuccess: true };
3636
} else {
3737
throw new Error("Create pool transaction reverted");

packages/nextjs/hooks/cow/useSetSwapFeeTxHash.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ export function useSetSwapFeeTxHash() {
4848

4949
if (swapFee !== MAX_FEE) throw new Error("Swap fee is not set to max fee");
5050

51-
updatePoolCreation({ setSwapFeeTx: { safeHash, wagmiHash, isSuccess: true }, step: poolCreation?.step + 1 });
51+
updatePoolCreation({ setSwapFeeTx: { safeHash, wagmiHash, isSuccess: true }, step: 7 });
5252
return { isSuccess: true };
5353
} else {
5454
throw new Error("Set swap fee transaction reverted");

0 commit comments

Comments
 (0)