interop: fix ConvertContextToReadOnly interop

The same bug as in #1804.
This commit is contained in:
Anna Shaleva 2021-03-04 11:51:32 +03:00
parent 0e7bb5cc77
commit 0c464083ed

View file

@ -43,7 +43,7 @@ const (
// using this new Context. If Context is already read-only this function is a // using this new Context. If Context is already read-only this function is a
// no-op. It uses `System.Storage.AsReadOnly` syscall. // no-op. It uses `System.Storage.AsReadOnly` syscall.
func ConvertContextToReadOnly(ctx Context) Context { func ConvertContextToReadOnly(ctx Context) Context {
return neogointernal.Syscall0("System.Storage.AsReadOnly").(Context) return neogointernal.Syscall1("System.Storage.AsReadOnly", ctx).(Context)
} }
// GetContext returns current contract's (that invokes this function) storage // GetContext returns current contract's (that invokes this function) storage