Skip to content

Commit ad8257b

Browse files
committedDec 11, 2024
fix time panic
1 parent b6d379b commit ad8257b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed
 

‎tools/amplify-preview/amplify.go

+4-1
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ func (amp *AmplifyPreview) StartJob(ctx context.Context, branch *types.Branch) (
141141
return nil, err
142142
}
143143

144-
logger.Info("Successfully started job", logKeyAppID, appID, logKeyBranchName, branch.BranchName, logKeyJobID, resp.JobSummary.JobId)
144+
logger.Info("Successfully started job", logKeyAppID, appID, logKeyBranchName, *branch.BranchName, logKeyJobID, *resp.JobSummary.JobId)
145145

146146
return resp.JobSummary, nil
147147

@@ -216,6 +216,9 @@ func amplifyJobToMarkdown(job *types.JobSummary, branch *types.Branch) string {
216216
if job.EndTime != nil {
217217
updateTime = job.EndTime
218218
}
219+
if updateTime == nil {
220+
updateTime = branch.CreateTime
221+
}
219222

220223
commentBody.WriteString(amplifyMarkdownHeader)
221224
commentBody.WriteByte('\n')

0 commit comments

Comments
 (0)