summaryrefslogtreecommitdiffstats
path: root/cache/filecache/filecache.go
diff options
context:
space:
mode:
Diffstat (limited to 'cache/filecache/filecache.go')
-rw-r--r--cache/filecache/filecache.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/cache/filecache/filecache.go b/cache/filecache/filecache.go
index 63d939ef6..8723c4bdc 100644
--- a/cache/filecache/filecache.go
+++ b/cache/filecache/filecache.go
@@ -17,7 +17,6 @@ import (
"bytes"
"errors"
"io"
- "io/ioutil"
"os"
"path/filepath"
"strings"
@@ -207,7 +206,7 @@ func (c *Cache) GetOrCreateBytes(id string, create func() ([]byte, error)) (Item
if r := c.getOrRemove(id); r != nil {
defer r.Close()
- b, err := ioutil.ReadAll(r)
+ b, err := io.ReadAll(r)
return info, b, err
}
@@ -242,7 +241,7 @@ func (c *Cache) GetBytes(id string) (ItemInfo, []byte, error) {
if r := c.getOrRemove(id); r != nil {
defer r.Close()
- b, err := ioutil.ReadAll(r)
+ b, err := io.ReadAll(r)
return info, b, err
}
@@ -314,7 +313,7 @@ func (c *Cache) getString(id string) string {
}
defer f.Close()
- b, _ := ioutil.ReadAll(f)
+ b, _ := io.ReadAll(f)
return string(b)
}