client: allow transfer method to read states

Makes no sense disabling it with writes enabled. Fixes #1725.
This commit is contained in:
Roman Khimov 2021-02-11 18:55:16 +03:00
parent 2a1e33b8c9
commit 8cd37c781c

View file

@ -129,8 +129,8 @@ func (c *Client) CreateNEP17MultiTransferTx(acc *wallet.Account, gas int64, reci
} }
w := io.NewBufBinWriter() w := io.NewBufBinWriter()
for i := range recipients { for i := range recipients {
emit.AppCall(w.BinWriter, recipients[i].Token, "transfer", emit.AppCall(w.BinWriter, recipients[i].Token, "transfer", callflag.All,
callflag.WriteStates|callflag.AllowCall|callflag.AllowNotify, from, recipients[i].Address, recipients[i].Amount, data[i]) from, recipients[i].Address, recipients[i].Amount, data[i])
emit.Opcodes(w.BinWriter, opcode.ASSERT) emit.Opcodes(w.BinWriter, opcode.ASSERT)
} }
if w.Err != nil { if w.Err != nil {