0
0
mirror of https://github.com/go-gitea/gitea.git synced 2026-05-11 17:55:32 +02:00

Fix remaining ToActionWorkflowRun call sites after signature change

Pass repo parameter to ToActionWorkflowRun in action.go and shared/action.go.

Co-Authored-By: Claude Sonnet 4.6 <claude-sonnet-4-6@anthropic.com>
This commit is contained in:
Ross Golder 2026-05-02 10:23:15 +07:00
parent 2975f8be8f
commit 15b0e6bfd5
No known key found for this signature in database
GPG Key ID: 253A7E508D2D59CD
2 changed files with 4 additions and 4 deletions

View File

@ -1233,7 +1233,7 @@ func GetWorkflowRun(ctx *context.APIContext) {
return
}
convertedRun, err := convert.ToActionWorkflowRun(ctx, run, nil)
convertedRun, err := convert.ToActionWorkflowRun(ctx, ctx.Repo.Repository, run, nil)
if err != nil {
ctx.APIErrorInternal(err)
return
@ -1282,7 +1282,7 @@ func GetWorkflowRunAttempt(ctx *context.APIContext) {
return
}
convertedRun, err := convert.ToActionWorkflowRun(ctx, run, attempt)
convertedRun, err := convert.ToActionWorkflowRun(ctx, ctx.Repo.Repository, run, attempt)
if err != nil {
ctx.APIErrorInternal(err)
return
@ -1337,7 +1337,7 @@ func RerunWorkflowRun(ctx *context.APIContext) {
return
}
convertedRun, err := convert.ToActionWorkflowRun(ctx, run, nil)
convertedRun, err := convert.ToActionWorkflowRun(ctx, ctx.Repo.Repository, run, nil)
if err != nil {
ctx.APIErrorInternal(err)
return

View File

@ -197,7 +197,7 @@ func ListRuns(ctx *context.APIContext, ownerID, repoID int64) {
res.Entries = make([]*api.ActionWorkflowRun, len(runs))
for i := range runs {
// TODO: load run attempts in batch
convertedRun, err := convert.ToActionWorkflowRun(ctx, runs[i], nil)
convertedRun, err := convert.ToActionWorkflowRun(ctx, runs[i].Repo, runs[i], nil)
if err != nil {
ctx.APIErrorInternal(err)
return