@@ -157,10 +157,12 @@ export class Sync implements Contracts.ApiSync.Service {
157157 }
158158 }
159159
160- const dirtyValidators = this . validatorSet . getDirtyValidators ( ) . reduce ( ( accumulator , current ) => {
161- accumulator [ current . address ] = current ;
162- return accumulator ;
163- } , { } ) ;
160+ const dirtyValidators : Record < string , Contracts . State . ValidatorWallet > = this . validatorSet
161+ . getDirtyValidators ( )
162+ . reduce ( ( accumulator , current ) => {
163+ accumulator [ current . address ] = current ;
164+ return accumulator ;
165+ } , { } ) ;
164166
165167 const accountUpdates : Record < string , Contracts . Evm . AccountUpdate > = unit
166168 . getAccountUpdates ( )
@@ -176,6 +178,7 @@ export class Sync implements Contracts.ApiSync.Service {
176178 return {
177179 ...( dirtyValidator
178180 ? {
181+ validatorFee : dirtyValidator . fee ,
179182 validatorPublicKey : dirtyValidator . blsPublicKey ,
180183 validatorResigned : dirtyValidator . isResigned ,
181184 validatorVoteBalance : dirtyValidator . voteBalance ,
@@ -486,6 +489,8 @@ export class Sync implements Contracts.ApiSync.Service {
486489 COALESCE((EXCLUDED.attributes->>'validatorVoteBalance')::text, ("Wallet".attributes->>'validatorVoteBalance')::text),
487490 'validatorVotersCount',
488491 COALESCE(EXCLUDED.attributes->'validatorVotersCount', "Wallet".attributes->'validatorVotersCount'),
492+ 'validatorFee',
493+ COALESCE((EXCLUDED.attributes->>'validatorFee')::text, ("Wallet".attributes->>'validatorFee')::text),
489494 'validatorLastBlock',
490495 COALESCE((EXCLUDED.attributes->>'validatorLastBlock')::jsonb, ("Wallet".attributes->>'validatorLastBlock')::jsonb),
491496 'validatorForgedFees',
0 commit comments