io: rename ReadBytes() to ReadVarBytes()

This commit is contained in:
Evgenii Stratonikov 2019-12-06 18:37:37 +03:00
parent f01fc1cc29
commit 838050f8b5
14 changed files with 22 additions and 22 deletions

View file

@ -102,14 +102,14 @@ func DecodeBinaryStackItem(r *io.BinReader) StackItem {
switch stackItemType(t) {
case byteArrayT:
data := r.ReadBytes()
data := r.ReadVarBytes()
return NewByteArrayItem(data)
case booleanT:
var b bool
r.ReadLE(&b)
return NewBoolItem(b)
case integerT:
data := r.ReadBytes()
data := r.ReadVarBytes()
num := new(big.Int).SetBytes(util.ArrayReverse(data))
return &BigIntegerItem{
value: num,