update to 1.16 and removes usage of "io/ioutil"
This commit is contained in:
@ -3,7 +3,7 @@ package nbt
|
||||
import (
|
||||
"bytes"
|
||||
"compress/gzip"
|
||||
"io/ioutil"
|
||||
"io"
|
||||
"reflect"
|
||||
"testing"
|
||||
)
|
||||
@ -225,7 +225,7 @@ func TestMarshal_bigTest(t *testing.T) {
|
||||
}
|
||||
|
||||
rd, _ := gzip.NewReader(bytes.NewReader(bigTestData[:]))
|
||||
want, err := ioutil.ReadAll(rd)
|
||||
want, err := io.ReadAll(rd)
|
||||
if err != nil {
|
||||
t.Error(err)
|
||||
}
|
||||
|
@ -5,7 +5,6 @@ import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"math"
|
||||
"reflect"
|
||||
)
|
||||
@ -382,7 +381,7 @@ func (d *Decoder) rawRead(tagType byte) error {
|
||||
return err
|
||||
}
|
||||
|
||||
if _, err = io.CopyN(ioutil.Discard, d.r, int64(aryLen)); err != nil {
|
||||
if _, err = io.CopyN(io.Discard, d.r, int64(aryLen)); err != nil {
|
||||
return err
|
||||
}
|
||||
case TagIntArray:
|
||||
|
Reference in New Issue
Block a user