mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-15 17:30:44 +00:00
parent
a5eab7eddb
commit
525a84eae4
1 changed files with 1 additions and 1 deletions
|
|
@ -85,7 +85,7 @@ func fromBuf(vm *goja.Runtime, bufType goja.Value, buf goja.Value, allowString b
|
||||||
if !obj.Get("constructor").SameAs(bufType) {
|
if !obj.Get("constructor").SameAs(bufType) {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
b := obj.Get("buffer").Export().(goja.ArrayBuffer).Bytes()
|
b := obj.Export().([]byte)
|
||||||
return b, nil
|
return b, nil
|
||||||
}
|
}
|
||||||
return nil, errors.New("invalid buffer type")
|
return nil, errors.New("invalid buffer type")
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue