forked from forgejo/forgejo
Move milestone to models/issues/ (#19278)
* Move milestone to models/issues/ * Fix lint * Fix test * Fix lint * Fix lint
This commit is contained in:
parent
84ceaa98bd
commit
1dfa26e00e
56 changed files with 466 additions and 447 deletions
|
@ -157,11 +157,11 @@ func FinishIssueStopwatch(ctx context.Context, user *user_model.User, issue *Iss
|
|||
return err
|
||||
}
|
||||
|
||||
if err := issue.loadRepo(ctx); err != nil {
|
||||
if err := issue.LoadRepo(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if _, err := createComment(ctx, &CreateCommentOptions{
|
||||
if _, err := CreateCommentCtx(ctx, &CreateCommentOptions{
|
||||
Doer: user,
|
||||
Issue: issue,
|
||||
Repo: issue.Repo,
|
||||
|
@ -178,7 +178,7 @@ func FinishIssueStopwatch(ctx context.Context, user *user_model.User, issue *Iss
|
|||
// CreateIssueStopwatch creates a stopwatch if not exist, otherwise return an error
|
||||
func CreateIssueStopwatch(ctx context.Context, user *user_model.User, issue *Issue) error {
|
||||
e := db.GetEngine(ctx)
|
||||
if err := issue.loadRepo(ctx); err != nil {
|
||||
if err := issue.LoadRepo(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
|
@ -208,11 +208,11 @@ func CreateIssueStopwatch(ctx context.Context, user *user_model.User, issue *Iss
|
|||
return err
|
||||
}
|
||||
|
||||
if err := issue.loadRepo(ctx); err != nil {
|
||||
if err := issue.LoadRepo(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if _, err := createComment(ctx, &CreateCommentOptions{
|
||||
if _, err := CreateCommentCtx(ctx, &CreateCommentOptions{
|
||||
Doer: user,
|
||||
Issue: issue,
|
||||
Repo: issue.Repo,
|
||||
|
@ -249,11 +249,11 @@ func cancelStopwatch(ctx context.Context, user *user_model.User, issue *Issue) e
|
|||
return err
|
||||
}
|
||||
|
||||
if err := issue.loadRepo(ctx); err != nil {
|
||||
if err := issue.LoadRepo(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if _, err := createComment(ctx, &CreateCommentOptions{
|
||||
if _, err := CreateCommentCtx(ctx, &CreateCommentOptions{
|
||||
Doer: user,
|
||||
Issue: issue,
|
||||
Repo: issue.Repo,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue