Fix withUpdates
This commit is contained in:
parent
8f1c2b7aa9
commit
e3a22d2027
@ -26,12 +26,12 @@ func withUpdates(updates ...update) interface{} {
|
||||
vmctx := args[1].Interface().(types.VMContext)
|
||||
|
||||
for _, u := range updates {
|
||||
if u.start >= vmctx.BlockHeight() {
|
||||
if vmctx.BlockHeight() >= u.start {
|
||||
return reflect.ValueOf(u.method).Call(args)
|
||||
}
|
||||
}
|
||||
|
||||
return reflect.ValueOf(notFound(vmctx)).Call([]reflect.Value{args[1]})
|
||||
return reflect.ValueOf(notFound(vmctx)).Call([]reflect.Value{})
|
||||
})
|
||||
|
||||
return out.Interface()
|
||||
|
Loading…
Reference in New Issue
Block a user