mirror of
https://github.com/offen/docker-volume-backup.git
synced 2025-09-05 22:14:27 +08:00
Replace deprecated lib usage
This commit is contained in:
parent
450dab19b7
commit
3f4d33cd8c
1 changed files with 2 additions and 3 deletions
|
@ -6,7 +6,6 @@ package googledrive
|
|||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
@ -38,8 +37,8 @@ type Config struct {
|
|||
|
||||
// NewStorageBackend creates and initializes a new Google Drive storage backend.
|
||||
func NewStorageBackend(opts Config, logFunc storage.Log) (storage.Backend, error) {
|
||||
ctx := context.Background()
|
||||
b, err := ioutil.ReadFile(opts.CredentialsJSON)
|
||||
ctx := context.Background()
|
||||
b, err := os.ReadFile(opts.CredentialsJSON)
|
||||
if err != nil {
|
||||
return nil, errwrap.Wrap(err, "unable to read credentials")
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue