Skip to content

Commit

Permalink
Merge pull request #308 from prevostc/add-stargate-support
Browse files Browse the repository at this point in the history
beefy : yield : Add stargate support
  • Loading branch information
0xroll authored Oct 28, 2024
2 parents ae6e258 + c943313 commit 062790f
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 6 deletions.
3 changes: 2 additions & 1 deletion adapters/beefy/hourly_blocks.csv
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ number,timestamp
6301186,1720005441
7643069,1722689579
7848072,1723099948
8029967,1723464243
8029967,1723464243
11330508,1730124321
4 changes: 2 additions & 2 deletions adapters/beefy/src/sdk/breakdown/getVaultBreakdown.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { BeefyVaultBreakdown } from "./types";
import { BeefyViemClient, getViemClient } from "../viemClient";
import { getSolidlyVaultBreakdown } from "./protocol_type/solidly";
import { getGammaVaultBreakdown } from "./protocol_type/gamma";
import { getMendiVaultBreakdown } from "./protocol_type/mendi";
import { getSingleTokenVaultBreakdown } from "./protocol_type/single_token";
import {
getBeefyClmManagerBreakdown,
getBeefyClmVaultBreakdown,
Expand All @@ -17,7 +17,7 @@ type BreakdownMethod = (

const breakdownMethods: Record<BeefyProtocolType, BreakdownMethod> = {
solidly: getSolidlyVaultBreakdown,
mendi: getMendiVaultBreakdown,
single_token: getSingleTokenVaultBreakdown,
gamma: getGammaVaultBreakdown,
ichi: getGammaVaultBreakdown,
beefy_clm: getBeefyClmManagerBreakdown,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { BeefyViemClient } from "../../viemClient";
import { BeefyVaultBreakdown } from "../types";
import { BeefyVaultV7Abi } from "../../../abi/BeefyVaultV7Abi";

export const getMendiVaultBreakdown = async (
export const getSingleTokenVaultBreakdown = async (
client: BeefyViemClient,
blockNumber: bigint,
vault: BeefyVault
Expand Down
6 changes: 4 additions & 2 deletions adapters/beefy/src/sdk/vault/getBeefyVaultConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export type BeefyBoost = {
export type BeefyProtocolType =
| "gamma"
| "ichi"
| "mendi"
| "single_token"
| "solidly"
| "beefy_clm"
| "beefy_clm_vault";
Expand All @@ -52,6 +52,7 @@ type ApiPlatformId =
| "lynex"
| "mendi"
| "nile"
| "stargate"
| "velodrome"
| "beefy"; // and more but we don't use those on linea

Expand Down Expand Up @@ -133,10 +134,11 @@ const protocol_map: Record<ApiPlatformId, BeefyProtocolType> = {
gamma: "gamma",
ichi: "ichi",
lynex: "solidly",
mendi: "mendi",
mendi: "single_token",
nile: "solidly",
velodrome: "solidly",
beefy: "beefy_clm",
stargate: "single_token",
};

export const getBeefyVaultConfig = memoize(
Expand Down

0 comments on commit 062790f

Please sign in to comment.