0g-chain/x/kavadist/spec/06_begin_block.md

17 lines
299 B
Markdown
Raw Normal View History

<!--
order: 6
-->
2020-05-07 17:45:32 +00:00
# Begin Block
At the start of each block, the inflationary coins for the ongoing period, if any, are minted. The logic is as follows:
```go
func BeginBlocker(ctx sdk.Context, k Keeper) {
err := k.MintPeriodInflation(ctx)
if err != nil {
panic(err)
}
}
```