From 788796d4e09d6925c8763754721ad7fc0b771486 Mon Sep 17 00:00:00 2001 From: Soil King <157099073+soilking@users.noreply.github.com> Date: Tue, 9 Apr 2024 15:09:37 -0700 Subject: [PATCH] subgraph: fix compilation --- projects/subgraph-beanstalk/src/GaugeHandler.ts | 6 +++--- projects/subgraph-beanstalk/subgraph.yaml | 2 -- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/projects/subgraph-beanstalk/src/GaugeHandler.ts b/projects/subgraph-beanstalk/src/GaugeHandler.ts index 930374cd3b..60f485a229 100644 --- a/projects/subgraph-beanstalk/src/GaugeHandler.ts +++ b/projects/subgraph-beanstalk/src/GaugeHandler.ts @@ -21,14 +21,14 @@ export function handleTemperatureChange(event: TemperatureChange): void { export function handleBeanToMaxLpGpPerBdvRatioChange(event: BeanToMaxLpGpPerBdvRatioChange): void { let silo = loadSilo(event.address); - if (silo.beanToMaxLpGpPerBdvRatio == null) { + if (silo.beanToMaxLpGpPerBdvRatio === null) { silo.beanToMaxLpGpPerBdvRatio = event.params.absChange; } else { - silo.beanToMaxLpGpPerBdvRatio = silo.beanToMaxLpGpPerBdvRatio.plus(event.params.absChange); + silo.beanToMaxLpGpPerBdvRatio = silo.beanToMaxLpGpPerBdvRatio!.plus(event.params.absChange); } silo.save(); - let siloHourly = loadSiloHourlySnapshot(event.address, event.params.season, event.block.timestamp); + let siloHourly = loadSiloHourlySnapshot(event.address, event.params.season.toI32(), event.block.timestamp); siloHourly.caseId = event.params.caseId; siloHourly.save(); } diff --git a/projects/subgraph-beanstalk/subgraph.yaml b/projects/subgraph-beanstalk/subgraph.yaml index 61f063d069..3921a37601 100644 --- a/projects/subgraph-beanstalk/subgraph.yaml +++ b/projects/subgraph-beanstalk/subgraph.yaml @@ -763,8 +763,6 @@ dataSources: handler: handleUpdateGaugeSettings - event: UpdateAverageStalkPerBdvPerSeason(uint256) handler: handleUpdateAverageStalkPerBdvPerSeason - - event: UpdatedStalkPerBdvPerSeason(indexed address,uint32,uint32) - handler: handleUpdateStalkPerBdvPerSeason - event: WhitelistToken(indexed address,bytes4,uint32,uint256,bytes4,bytes4,uint128,uint64) handler: handleWhitelistToken_BIP42 file: ./src/GaugeHandler.ts