Skip to content

Commit

Permalink
Revert "undefined"
Browse files Browse the repository at this point in the history
This reverts commit c5f5f3c.
  • Loading branch information
girazoki committed Feb 12, 2025
1 parent c5f5f3c commit 27fbaff
Showing 1 changed file with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -316,14 +316,12 @@ describeSuite({
// In new era's first session at least one block need to be produced by the operator
const blocksPerSession = 10;
for (let i = 0; i < 3 * blocksPerSession; ++i) {
const latestBlockHash = await relayApi.rpc.chain.getFinalizedHead();
const latestBlockHash = await relayApi.rpc.chain.getBlockHash();
const author = (await relayApi.derive.chain.getHeader(latestBlockHash)).author;
if (typeof author !== "undefined") {
if (author.toString() === operatorAccount.address) {
return;
}
await context.waitBlock(1, "Tanssi-relay");
if (author.toString() === operatorAccount.address) {
return;
}
await context.waitBlock(1, "Tanssi-relay");
}
expect.fail("operator didn't produce a block");
},
Expand Down

0 comments on commit 27fbaff

Please sign in to comment.