Skip to content

Commit

Permalink
fix: optimism hotfix
Browse files Browse the repository at this point in the history
  • Loading branch information
doomsower committed Aug 10, 2024
1 parent f45bc62 commit e870fa9
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion src/services/RedstoneServiceV3.ts
Original file line number Diff line number Diff line change
Expand Up @@ -129,10 +129,25 @@ export class RedstoneServiceV3 {
{ ticker },
`will update redstone ticker ${ticker.symbol} for ${symb}`,
);
// TODO:
// this is hotfix
// Previous assumption was that tickers are always added as main feed
// this is not true, and for "ezETH/ETH" this is reserve
//
// need to unwrap composite price feeds and determine reserve status
// or wait for price feed compressor
let reserve = false;
if (
ticker.symbol === "ezETH/ETH" &&
this.config.network === "Optimism"
) {
reserve = true;
}

redstoneUpdates.push({
dataFeedId: ticker.dataId,
token: ticker.address,
reserve: false, // tickers are always added as main feed
reserve,
});
} else {
logger.debug(
Expand Down

0 comments on commit e870fa9

Please sign in to comment.