Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: Raghav Kaul <[email protected]>
  • Loading branch information
raghavkaul committed Apr 17, 2023
1 parent 7e0af93 commit 8397220
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion clients/gitlabrepo/branches.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,10 @@ func (handler *branchesHandler) setup() error {

projectStatusChecks, resp, err := handler.glClient.ExternalStatusChecks.ListProjectStatusChecks(
handler.repourl.project, &gitlab.ListOptions{})
if err != nil && resp.StatusCode != 404 {
if (err != nil || resp.StatusCode != 404) &&
resp.StatusCode != 401 { // 401: permissions. pass token authorization issues silently
handler.errSetup = fmt.Errorf("request for external status checks failed with error %w", err)
return
}

projectApprovalRule, resp, err := handler.glClient.Projects.GetApprovalConfiguration(handler.repourl.project)
Expand Down

0 comments on commit 8397220

Please sign in to comment.