diff options
author | Niall Sheridan <nsheridan@gmail.com> | 2016-10-31 16:36:17 +0000 |
---|---|---|
committer | Niall Sheridan <nsheridan@gmail.com> | 2016-10-31 16:40:08 +0000 |
commit | e0a1ccb64a637673195804513902cba6b1d4e97c (patch) | |
tree | abc1598be28cda231d92cda8fb10b49eeb564c29 /vendor/github.com/hashicorp/vault | |
parent | 7bad329d417f19ba4aae2b4607281c2bc5df8ad7 (diff) |
Update dependencies
Diffstat (limited to 'vendor/github.com/hashicorp/vault')
-rw-r--r-- | vendor/github.com/hashicorp/vault/api/logical.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vendor/github.com/hashicorp/vault/api/logical.go b/vendor/github.com/hashicorp/vault/api/logical.go index f1cea7d..9753e96 100644 --- a/vendor/github.com/hashicorp/vault/api/logical.go +++ b/vendor/github.com/hashicorp/vault/api/logical.go @@ -119,7 +119,7 @@ func (c *Logical) Delete(path string) (*Secret, error) { func (c *Logical) Unwrap(wrappingToken string) (*Secret, error) { var data map[string]interface{} - if wrappingToken != "" { + if wrappingToken != "" && wrappingToken != c.c.Token() { data = map[string]interface{}{ "token": wrappingToken, } @@ -146,7 +146,7 @@ func (c *Logical) Unwrap(wrappingToken string) (*Secret, error) { return nil, nil } - if wrappingToken == "" { + if wrappingToken != "" { origToken := c.c.Token() defer c.c.SetToken(origToken) c.c.SetToken(wrappingToken) |