Skip to content

Commit 589ca44

Browse files
authored
Revert "fix: dai on optimism (gitcoinco#2214)" (gitcoinco#2217)
This reverts commit e2257d7.
1 parent e2257d7 commit 589ca44

2 files changed

Lines changed: 1 addition & 28 deletions

File tree

packages/grant-explorer/src/checkoutStore.ts

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -262,21 +262,6 @@ export const useCheckoutStore = create<CheckoutState>()(
262262
: undefined
263263
);
264264

265-
if (receipt.status === "reverted") {
266-
console.error(
267-
`vote on chain ${chainId} - roundIds ${Object.keys(
268-
donations.map((d) => d.roundId)
269-
)}, token ${token.name}`,
270-
receipt,
271-
sig,
272-
token
273-
);
274-
275-
throw new Error("vote failed", {
276-
cause: receipt,
277-
});
278-
}
279-
280265
console.log(
281266
"Voting succesful for chain",
282267
chainId,

packages/grant-explorer/src/features/round/ViewCartPage/CartWithProjects.tsx

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import {
33
getPayoutTokenOptions,
44
GroupedCartProjectsByRoundId,
55
} from "../../api/utils";
6-
import React, { useEffect, useState } from "react";
6+
import React, { useState } from "react";
77
import { PayoutToken } from "../../api/types";
88
import { PayoutTokenDropdown } from "./PayoutTokenDropdown";
99
import { ApplyTooltip } from "./ApplyTooltip";
@@ -39,18 +39,6 @@ export function CartWithProjects({ cart, chainId }: Props) {
3939
// get number of projects in cartByRound
4040
const projectCount = cartByRound.reduce((acc, curr) => acc + curr.length, 0);
4141

42-
/** The payout token data (like permit version etc.) might've changed since the user last visited the page
43-
* Refresh it to update, default to the first payout token if the previous token was deleted */
44-
useEffect(() => {
45-
setPayoutTokenForChain(
46-
chainId,
47-
getPayoutTokenOptions(chainId).find(
48-
(token) => token.address === selectedPayoutToken.address
49-
) ?? getPayoutTokenOptions(chainId)[0]
50-
);
51-
/* We only want this to happen on first render */
52-
}, [chainId, selectedPayoutToken.address, setPayoutTokenForChain]);
53-
5442
return (
5543
<div className="grow block px-[16px] py-4 bg-white">
5644
<div className="flex flex-col md:flex-row justify-between border-b-2 pb-2 gap-3 mb-6">

0 commit comments

Comments
 (0)