License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
This commit is contained in:
Jakub Sztandera 2019-09-19 15:37:45 +02:00
parent 54e076b6f9
commit 6fe32f55fc

View File

@ -67,7 +67,7 @@ func (vmc *VMContext) Message() *types.Message {
}
func (vmc *VMContext) GetRandomness(height uint64) ([]byte, aerrors.ActorError) {
relHeight := int(vmc.BlockHeight) - int(height)
relHeight := int(vmc.BlockHeight()) - int(height)
res, err := vmc.vm.cs.GetRandomness(vmc.ctx, vmc.vm.cs.GetHeaviestTipSet(), nil, relHeight)
if err != nil {
return nil, aerrors.Escalate(err, "could not get randomness")