Skip to content

Commit

Permalink
[#109] (internal/gitlab) prevent panic when unable to connect to gitl…
Browse files Browse the repository at this point in the history
…ab server
  • Loading branch information
zaquestion committed Feb 17, 2018
1 parent ce88fa0 commit 5c85a53
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/gitlab/gitlab.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ func FindProject(project string) (*gitlab.Project, error) {
}

target, resp, err := lab.Projects.GetProject(search)
if resp.StatusCode == http.StatusNotFound {
if resp != nil && resp.StatusCode == http.StatusNotFound {
return nil, ErrProjectNotFound
}
if err != nil {
Expand Down

0 comments on commit 5c85a53

Please sign in to comment.