mirror of
https://github.com/pgsty/minio.git
synced 2026-07-19 20:20:25 +03:00
Remove deprecated io/ioutil (#15707)
This commit is contained in:
@@ -20,7 +20,7 @@ package cmd
|
||||
import (
|
||||
"bufio"
|
||||
"bytes"
|
||||
"io/ioutil"
|
||||
"io"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"sort"
|
||||
@@ -49,7 +49,7 @@ func BenchmarkLockArgs(b *testing.B) {
|
||||
b.ReportAllocs()
|
||||
b.ResetTimer()
|
||||
for i := 0; i < b.N; i++ {
|
||||
req.Body = ioutil.NopCloser(bytes.NewReader(argBytes))
|
||||
req.Body = io.NopCloser(bytes.NewReader(argBytes))
|
||||
getLockArgs(req)
|
||||
}
|
||||
}
|
||||
@@ -68,7 +68,7 @@ func BenchmarkLockArgsOld(b *testing.B) {
|
||||
b.ReportAllocs()
|
||||
b.ResetTimer()
|
||||
for i := 0; i < b.N; i++ {
|
||||
req.Body = ioutil.NopCloser(bytes.NewReader([]byte(`obj.txt`)))
|
||||
req.Body = io.NopCloser(bytes.NewReader([]byte(`obj.txt`)))
|
||||
getLockArgsOld(req)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user