forked from TrueCloudLab/neoneo-go
core: adjust Neo.Native.Deploy interop
Part of #1055. It could be that context.Block is nill.
This commit is contained in:
parent
2bbe218547
commit
6e44499cec
1 changed files with 1 additions and 1 deletions
|
@ -12,7 +12,7 @@ import (
|
||||||
|
|
||||||
// Deploy deploys native contract.
|
// Deploy deploys native contract.
|
||||||
func Deploy(ic *interop.Context, _ *vm.VM) error {
|
func Deploy(ic *interop.Context, _ *vm.VM) error {
|
||||||
if ic.Block.Index != 0 {
|
if ic.Block == nil || ic.Block.Index != 0 {
|
||||||
return errors.New("native contracts can be deployed only at 0 block")
|
return errors.New("native contracts can be deployed only at 0 block")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue