8000 chore: change build audit log string to be clearer by Kira-Pilot · Pull Request #6093 · coder/coder · GitHub
[go: up one dir, main page]

Skip to content

chore: change build audit log string to be clearer #6093

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Feb 8, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
clean up friendly string
  • Loading branch information
Kira-Pilot committed Feb 7, 2023
commit 7f71c2a6fc5cd867f610e1cd9959aed1b3d3978e
13 changes: 0 additions & 13 deletions coderd/audit.go
Original file line number Diff line number Diff line change
Expand Up @@ -270,19 +270,6 @@ func auditLogDescription(alog database.GetAuditLogsOffsetRow, additionalFields a
return str
}

// Strings for starting/stopping workspace builds follow the below format:
// "{user | 'Coder automatically'} started build #{build_number} for workspace {target}"
// where target is a workspace (name) instead of a workspace build
// passed in on the FE via AuditLog.AdditionalFields rather than derived in request.go:35
if alog.ResourceType == database.ResourceTypeWorkspaceBuild && alog.Action != database.AuditActionDelete {
if len(additionalFields.BuildNumber) == 0 {
str += " build for"
} else {
str += fmt.Sprintf(" build #%s for",
additionalFields.BuildNumber)
}
}

// We don't display the name (target) for git ssh keys. It's fairly long and doesn't
// make too much sense to display.
if alog.ResourceType == database.ResourceTypeGitSshKey {
Expand Down
0