compiler: rename engine.AppCall() to contract.Call()

This commit is contained in:
Evgenii Stratonikov 2020-12-08 14:11:06 +03:00
parent d828096cbf
commit b807fd9e7f
5 changed files with 20 additions and 31 deletions

View file

@ -3,7 +3,6 @@ package timer
import (
"github.com/nspcc-dev/neo-go/pkg/interop/binary"
"github.com/nspcc-dev/neo-go/pkg/interop/contract"
"github.com/nspcc-dev/neo-go/pkg/interop/engine"
"github.com/nspcc-dev/neo-go/pkg/interop/runtime"
"github.com/nspcc-dev/neo-go/pkg/interop/storage"
"github.com/nspcc-dev/neo-go/pkg/interop/util"
@ -54,7 +53,7 @@ func Tick() bool {
ticksLeft = ticksLeft.(int) - 1
if ticksLeft == 0 {
runtime.Log("Fired!")
return engine.AppCall(runtime.GetExecutingScriptHash(), "selfDestroy").(bool)
return contract.Call(runtime.GetExecutingScriptHash(), "selfDestroy").(bool)
}
storage.Put(ctx, ticksKey, ticksLeft)
i := binary.Itoa(ticksLeft.(int), 10)