graph-network-subgraph
graph-network-subgraph copied to clipboard
Remove unused comparison for old and new end block
https://github.com/graphprotocol/graph-network-subgraph/pull/107#discussion_r609076614
- epoch start block = 1000
- epoch end block = 3000
then we halve the epoch length. so now it will be
let newEndBlock = 1000 + 1000
if (3000 != 2000) {
epoch.endBlock = 2000
epoch.save()
}
but if we double the epoch length we get
let newEndBlock = 1000 + 4000
if (3000 != 5000) {
epoch.endBlock = 5000
epoch.save()
}