mirror of
https://github.com/go-gitea/gitea.git
synced 2025-07-23 13:55:53 +02:00
fix: use new Status
This commit is contained in:
parent
c756f3081d
commit
6cdbf3e986
@ -9,7 +9,6 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"code.gitea.io/gitea/core"
|
|
||||||
"code.gitea.io/gitea/models/db"
|
"code.gitea.io/gitea/models/db"
|
||||||
repo_model "code.gitea.io/gitea/models/repo"
|
repo_model "code.gitea.io/gitea/models/repo"
|
||||||
user_model "code.gitea.io/gitea/models/user"
|
user_model "code.gitea.io/gitea/models/user"
|
||||||
@ -98,14 +97,8 @@ func updateRepoRunsNumbers(ctx context.Context, repo *repo_model.Repository) err
|
|||||||
builder.Select("count(*)").From("bots_run").
|
builder.Select("count(*)").From("bots_run").
|
||||||
Where(builder.Eq{
|
Where(builder.Eq{
|
||||||
"repo_id": repo.ID,
|
"repo_id": repo.ID,
|
||||||
}.And(
|
"status": StatusFailure,
|
||||||
builder.In("status",
|
},
|
||||||
core.StatusFailing,
|
|
||||||
core.StatusKilled,
|
|
||||||
core.StatusPassing,
|
|
||||||
core.StatusError,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
).
|
).
|
||||||
Update(repo)
|
Update(repo)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user