88 getCarrySpread ,
99 calculateLidoAPR ,
1010 getGrossStakingRewards ,
11- getNodeOperatorRewards ,
1211 getNetStakingRewards ,
1312 getDailyLidoFees ,
1413} from 'utils' ;
@@ -17,9 +16,8 @@ import { getRebaseRewardFromCache, getShareRateFromCache } from 'utils';
1716
1817export const prepareBottomLine = async (
1918 history : VaultReport [ ] ,
20- nodeOperatorFeeBPs : bigint [ ] ,
19+ nodeOperatorAccruedFees : bigint [ ] ,
2120 vaultAddress : string ,
22- settledGrowth : bigint [ ] ,
2321) => {
2422 const bottomLine = [ ] ;
2523 const timestamp = [ ] ;
@@ -40,9 +38,8 @@ export const prepareBottomLine = async (
4038 const bottomLineValue = getBottomLine (
4139 current ,
4240 previous ,
43- nodeOperatorFeeBPs [ i ] ?? 0n ,
41+ nodeOperatorAccruedFees [ i ] ?? 0n ,
4442 stEthLiabilityRebaseRewards ,
45- settledGrowth [ i ] ?? 0n ,
4643 ) ;
4744
4845 bottomLine . push ( String ( bottomLineValue ) ) ;
@@ -70,8 +67,7 @@ export const prepareGrossStakingAPR = (history: VaultReport[]) => {
7067
7168export const prepareNetStakingAPR = (
7269 history : VaultReport [ ] ,
73- nodeOperatorFeeBPs : bigint [ ] ,
74- settledGrowth : bigint [ ] ,
70+ nodeOperatorAccruedFees : bigint [ ] ,
7571) => {
7672 const netStakingAPRPercent = [ ] ;
7773 const timestamp = [ ] ;
@@ -85,8 +81,7 @@ export const prepareNetStakingAPR = (
8581 const value = getNetStakingAPR (
8682 current ,
8783 previous ,
88- nodeOperatorFeeBPs [ i ] ?? 0n ,
89- settledGrowth [ i ] ?? 0n ,
84+ nodeOperatorAccruedFees [ i ] ?? 0n ,
9085 ) ;
9186
9287 netStakingAPRPercent . push ( value . apr_percent ) ;
@@ -97,9 +92,8 @@ export const prepareNetStakingAPR = (
9792
9893export const prepareCarrySpread = async (
9994 history : VaultReport [ ] ,
100- nodeOperatorFeeBPs : bigint [ ] ,
95+ nodeOperatorAccruedFees : bigint [ ] ,
10196 vaultAddress : string ,
102- settledGrowth : bigint [ ] ,
10397) => {
10498 const carrySpreadPercent = [ ] ;
10599 const timestamp = [ ] ;
@@ -120,9 +114,8 @@ export const prepareCarrySpread = async (
120114 const value = getCarrySpread (
121115 current ,
122116 previous ,
123- nodeOperatorFeeBPs [ i ] ?? 0n ,
117+ nodeOperatorAccruedFees [ i ] ?? 0n ,
124118 stEthLiabilityRebaseRewards ,
125- settledGrowth [ i ] ?? 0n ,
126119 ) ;
127120
128121 carrySpreadPercent . push ( value . apr_percent ) ;
@@ -175,8 +168,7 @@ export const prepareGrossStakingRewards = (history: VaultReport[]) => {
175168
176169export const prepareNodeOperatorRewards = (
177170 history : VaultReport [ ] ,
178- nodeOperatorFeeBPs : bigint [ ] ,
179- settledGrowth : bigint [ ] ,
171+ nodeOperatorAccruedFees : bigint [ ] ,
180172) => {
181173 const nodeOperatorRewards = [ ] ;
182174 const timestamp = [ ] ;
@@ -186,12 +178,7 @@ export const prepareNodeOperatorRewards = (
186178 const previous = history [ i - 1 ] ;
187179 if ( ! current || ! previous ) continue ;
188180
189- const value = getNodeOperatorRewards (
190- current ,
191- previous ,
192- nodeOperatorFeeBPs [ i ] ?? 0n ,
193- settledGrowth [ i ] ?? 0n ,
194- ) ;
181+ const value = nodeOperatorAccruedFees [ i ] ?? 0n ;
195182
196183 nodeOperatorRewards . push ( String ( formatEther ( value ) ) ) ;
197184 timestamp . push ( current . timestamp ) ;
@@ -201,8 +188,7 @@ export const prepareNodeOperatorRewards = (
201188
202189export const prepareNetStakingRewards = (
203190 history : VaultReport [ ] ,
204- nodeOperatorFeeBPs : bigint [ ] ,
205- settledGrowth : bigint [ ] ,
191+ nodeOperatorAccruedFees : bigint [ ] ,
206192) => {
207193 const netStakingRewards = [ ] ;
208194 const timestamp = [ ] ;
@@ -215,8 +201,7 @@ export const prepareNetStakingRewards = (
215201 const value = getNetStakingRewards (
216202 current ,
217203 previous ,
218- nodeOperatorFeeBPs [ i ] ?? 0n ,
219- settledGrowth [ i ] ?? 0n ,
204+ nodeOperatorAccruedFees [ i ] ?? 0n ,
220205 ) ;
221206
222207 netStakingRewards . push ( String ( formatEther ( value ) ) ) ;
0 commit comments