Make WrapInfo a pointer to match secret/auth in response

This commit is contained in:
Jeff Mitchell
2016-05-07 19:17:51 -04:00
parent f3a3fc3d55
commit e36f66000e
5 changed files with 23 additions and 13 deletions

View File

@@ -155,7 +155,7 @@ func respondLogical(w http.ResponseWriter, r *http.Request, path string, dataOnl
return
}
if resp.WrapInfo.Token != "" {
if resp.WrapInfo != nil && resp.WrapInfo.Token != "" {
httpResp = logical.HTTPResponse{
WrapInfo: &logical.HTTPWrapInfo{
Token: resp.WrapInfo.Token,