Simplify code found by simplicity audit of d6be98f

This commit is contained in:
Ian Gulliver
2026-10-23 13:05:14 -07:00
parent c337799147
commit 3c2932c8fb
26 changed files with 180 additions and 225 deletions
+1 -1
View File
@@ -25,7 +25,7 @@ func (m *Manager) SetAuditWorkflow(ctx context.Context, projectID, name, actor s
if err != nil {
return api.Project{}, err
}
if creator.GitName == "" || creator.GitEmail == "" {
if !creator.HasGitIdentity() {
return api.Project{}, fmt.Errorf("%w: audits run as the project's creator %s, who has no git identity", ErrInvalid, creator.Login)
}
}