Skip to content

Commit 507ad66

Browse files
authored
Omit empty fields in CodeBuildPhase (#428)
1 parent e7ef344 commit 507ad66

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

events/codebuild.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -157,17 +157,17 @@ type CodeBuildLogs struct {
157157

158158
// CodeBuildPhase represents the phase of a build and its details
159159
type CodeBuildPhase struct {
160-
PhaseContext []interface{} `json:"phase-context"`
160+
PhaseContext []interface{} `json:"phase-context,omitempty"`
161161

162162
StartTime CodeBuildTime `json:"start-time"`
163163

164-
EndTime CodeBuildTime `json:"end-time"`
164+
EndTime CodeBuildTime `json:"end-time,omitempty"`
165165

166-
Duration DurationSeconds `json:"duration-in-seconds"`
166+
Duration DurationSeconds `json:"duration-in-seconds,omitempty"`
167167

168168
PhaseType CodeBuildPhaseType `json:"phase-type"`
169169

170-
PhaseStatus CodeBuildPhaseStatus `json:"phase-status"`
170+
PhaseStatus CodeBuildPhaseStatus `json:"phase-status,omitempty"`
171171
}
172172

173173
// CodeBuildTime represents the time of the build

0 commit comments

Comments
 (0)