Skip to content

Commit

Permalink
remove extra ctx
Browse files Browse the repository at this point in the history
  • Loading branch information
lifangmoler committed Mar 4, 2019
1 parent 3556679 commit a5b9998
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions get_gcs.go
Expand Up @@ -27,8 +27,7 @@ func (g *GCSGetter) ClientMode(u *url.URL) (ClientMode, error) {
return 0, err
}

sctx := context.Background()
client, err := storage.NewClient(sctx)
client, err := storage.NewClient(ctx)
if err != nil {
return 0, err
}
Expand Down Expand Up @@ -82,8 +81,7 @@ func (g *GCSGetter) Get(dst string, u *url.URL) error {
return err
}

sctx := context.Background()
client, err := storage.NewClient(sctx)
client, err := storage.NewClient(ctx)
if err != nil {
return err
}
Expand Down Expand Up @@ -125,8 +123,7 @@ func (g *GCSGetter) GetFile(dst string, u *url.URL) error {
return err
}

sctx := context.Background()
client, err := storage.NewClient(sctx)
client, err := storage.NewClient(ctx)
if err != nil {
return err
}
Expand Down

0 comments on commit a5b9998

Please sign in to comment.