Skip to content

Commit

Permalink
fix(core-database): check for missed blocks before applying round (#3507
Browse files Browse the repository at this point in the history
)
  • Loading branch information
alessiodf committed Feb 17, 2020
1 parent 454a125 commit 6d4c00a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/core-database/src/database-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,14 @@ export class DatabaseService implements Database.IDatabaseService {
this.blocksInCurrentRound.push(block);
}

this.detectMissedBlocks(block);

await this.applyRound(block.data.height);

for (const transaction of block.transactions) {
await this.emitTransactionEvents(transaction);
}

this.detectMissedBlocks(block);

this.emitter.emit(ApplicationEvents.BlockApplied, block.data);
}

Expand Down

0 comments on commit 6d4c00a

Please sign in to comment.