Skip to content

Commit

Permalink
remove deprecated of package io/ioutil (#13067)
Browse files Browse the repository at this point in the history
Signed-off-by: ChengenH <[email protected]>
  • Loading branch information
ChengenH authored Dec 12, 2024
1 parent 2e1582c commit a33cedf
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions cl/antiquary/antiquary.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ package antiquary

import (
"context"
"io/ioutil"
"math"
"os"
"strings"
"sync/atomic"
"time"
Expand Down Expand Up @@ -101,7 +101,7 @@ func NewAntiquary(ctx context.Context, blobStorage blob_storage.BlobStorage, gen
// Check if the snapshot directory has beacon blocks files aka "contains beaconblock" and has a ".seg" extension over its first layer
func doesSnapshotDirHaveBeaconBlocksFiles(snapshotDir string) bool {
// Iterate over the files in the snapshot directory
files, err := ioutil.ReadDir(snapshotDir)
files, err := os.ReadDir(snapshotDir)
if err != nil {
return false
}
Expand Down
4 changes: 2 additions & 2 deletions erigon-lib/log/v3/bench_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package log
import (
"bytes"
"errors"
"io/ioutil"
"io"
"testing"
"time"
)
Expand Down Expand Up @@ -134,7 +134,7 @@ func BenchmarkDescendant8(b *testing.B) {
// (MIT License)
func newLog15() Logger {
logger := New()
logger.SetHandler(StreamHandler(ioutil.Discard, JsonFormat()))
logger.SetHandler(StreamHandler(io.Discard, JsonFormat()))
return logger
}

Expand Down

0 comments on commit a33cedf

Please sign in to comment.