Skip to content

Commit

Permalink
Fixed VRF value at current height (#3474)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergey Nazarov authored May 13, 2021
1 parent cba985f commit 8b44f02
Show file tree
Hide file tree
Showing 23 changed files with 230 additions and 621 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,7 @@ object StateUpdate {

def atomic(blockchainBeforeWithMinerReward: Blockchain, diff: Diff): StateUpdate = {
val blockchain = blockchainBeforeWithMinerReward
val blockchainAfter = CompositeBlockchain(blockchain, Some(diff))
val blockchainAfter = CompositeBlockchain(blockchain, diff)

val PortfolioUpdates(updatedBalances, updatedLeaseBalances) = DiffToStateApplier.portfolios(blockchain, diff)

Expand Down Expand Up @@ -484,11 +484,11 @@ object StateUpdate {
.foldLeft((Seq.empty[StateUpdate], parentDiff)) {
case ((updates, accDiff), txDiff) =>
(
updates :+ atomic(CompositeBlockchain(blockchainBeforeWithMinerReward, Some(accDiff)), txDiff),
updates :+ atomic(CompositeBlockchain(blockchainBeforeWithMinerReward, accDiff), txDiff),
accDiff.combine(txDiff)
)
}
val blockchainAfter = CompositeBlockchain(blockchainBeforeWithMinerReward, Some(totalDiff))
val blockchainAfter = CompositeBlockchain(blockchainBeforeWithMinerReward, totalDiff)
val metadata = transactionsMetadata(blockchainAfter, totalDiff)
val refAssets = referencedAssets(blockchainAfter, txsStateUpdates)
(parentStateUpdateWithMinerReward, txsStateUpdates, metadata, refAssets)
Expand Down

This file was deleted.

This file was deleted.

Loading

0 comments on commit 8b44f02

Please sign in to comment.