Skip to content

Commit

Permalink
only return secret string instead of details struct
Browse files Browse the repository at this point in the history
  • Loading branch information
hooksie1 committed Aug 10, 2024
1 parent 6389ea5 commit ed8c2a7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion service/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,5 +80,10 @@ func (c *Client) Do(request Request) (string, error) {
return "", fmt.Errorf("status %s, details %v", code, respErr.Error)
}

return string(msg.Data), nil
var resp ResponseMessage
if err := json.Unmarshal(msg.Data, &resp); err != nil {
return "", err
}

return resp.Details, nil
}

0 comments on commit ed8c2a7

Please sign in to comment.