Skip to content

Commit

Permalink
get reward era length from chain
Browse files Browse the repository at this point in the history
  • Loading branch information
shannonwells committed Oct 30, 2024
1 parent 52b5d76 commit d0bf4df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion e2e/scaffolding/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -496,7 +496,7 @@ export async function setEpochLength(keys: KeyringPair, epochLength: number): Pr

export async function getNextRewardEraBlock(): Promise<number> {
const eraInfo = await ExtrinsicHelper.apiPromise.query.capacity.currentEraInfo();
const actualEraLength: number = 50;
const actualEraLength: number = ExtrinsicHelper.api.consts.capacity.eraLength.toNumber();
return actualEraLength + eraInfo.startedAt.toNumber() + 1;
}

Expand Down

0 comments on commit d0bf4df

Please sign in to comment.