core: extend error text for storage context in dynamic script

This commit is contained in:
Anna Shaleva 2022-11-28 11:44:24 +03:00
parent 0ceae612c6
commit 6d3cc0f7e7

View file

@ -70,7 +70,7 @@ func GetReadOnlyContext(ic *interop.Context) error {
func getContextInternal(ic *interop.Context, isReadOnly bool) error { func getContextInternal(ic *interop.Context, isReadOnly bool) error {
contract, err := ic.GetContract(ic.VM.GetCurrentScriptHash()) contract, err := ic.GetContract(ic.VM.GetCurrentScriptHash())
if err != nil { if err != nil {
return err return fmt.Errorf("storage context can not be retrieved in dynamic scripts: %w", err)
} }
sc := &Context{ sc := &Context{
ID: contract.ID, ID: contract.ID,