Skip to content

Commit 764123c

Browse files
author
Moritz Rieger
committed
fix: adding of duplicate commit statuses in gitlab
RESOLVES #1009 Signed-off-by: Moritz Rieger <[email protected]>
1 parent 7ee7239 commit 764123c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

internal/notifier/gitlab.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,9 @@ func (g *GitLab) Post(ctx context.Context, event eventv1.Event) error {
9999
Description: desc,
100100
}
101101

102-
getOpt := &gitlab.GetCommitStatusesOptions{}
102+
getOpt := &gitlab.GetCommitStatusesOptions{
103+
Name: &status.Name,
104+
}
103105
statuses, _, err := g.Client.Commits.GetCommitStatuses(g.Id, rev, getOpt, gitlab.WithContext(ctx))
104106
if err != nil {
105107
return fmt.Errorf("unable to list commit status: %s", err)

0 commit comments

Comments
 (0)