Skip to content

Commit ba34a19

Browse files
Baruch BilanskiBaruch Bilanski
authored andcommitted
more robust check
1 parent 76b005c commit ba34a19

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

client/client.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,8 +190,7 @@ func (cli *Client) GetUSEAuthToken() (string, string, error) {
190190

191191
request.Set("Authorization", "Bearer "+cli.token)
192192
events, body, errs := request.Clone().Get(provUrl + "/v1/envs").End()
193-
194-
if errs != nil {
193+
if errs != nil || events == nil {
195194
if events != nil {
196195
log.Println(events.StatusCode)
197196
}

0 commit comments

Comments
 (0)