diff options
author | Nathan Dench <ndenc2@gmail.com> | 2019-05-24 15:16:44 +1000 |
---|---|---|
committer | Nathan Dench <ndenc2@gmail.com> | 2019-05-24 15:16:44 +1000 |
commit | 107c1cdb09c575aa2f61d97f48d8587eb6bada4c (patch) | |
tree | ca7d008643efc555c388baeaf1d986e0b6b3e28c /vendor/github.com/hashicorp/go-getter/get_base.go | |
parent | 844b5a68d8af4791755b8f0ad293cc99f5959183 (diff) | |
download | terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.tar.gz terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.tar.zst terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.zip |
Upgrade to 0.12
Diffstat (limited to 'vendor/github.com/hashicorp/go-getter/get_base.go')
-rw-r--r-- | vendor/github.com/hashicorp/go-getter/get_base.go | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/vendor/github.com/hashicorp/go-getter/get_base.go b/vendor/github.com/hashicorp/go-getter/get_base.go new file mode 100644 index 0000000..09e9b63 --- /dev/null +++ b/vendor/github.com/hashicorp/go-getter/get_base.go | |||
@@ -0,0 +1,20 @@ | |||
1 | package getter | ||
2 | |||
3 | import "context" | ||
4 | |||
5 | // getter is our base getter; it regroups | ||
6 | // fields all getters have in common. | ||
7 | type getter struct { | ||
8 | client *Client | ||
9 | } | ||
10 | |||
11 | func (g *getter) SetClient(c *Client) { g.client = c } | ||
12 | |||
13 | // Context tries to returns the Contex from the getter's | ||
14 | // client. otherwise context.Background() is returned. | ||
15 | func (g *getter) Context() context.Context { | ||
16 | if g == nil || g.client == nil { | ||
17 | return context.Background() | ||
18 | } | ||
19 | return g.client.Ctx | ||
20 | } | ||