aboutsummaryrefslogtreecommitdiffstats
path: root/modules/notification/action
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2022-04-08 17:11:15 +0800
committerGitHub <noreply@github.com>2022-04-08 17:11:15 +0800
commit1dfa26e00e8e1ce6f6125335871da1d402a63466 (patch)
treed39414fb085ae52d6633ae9d064aabab2e7f75f8 /modules/notification/action
parent84ceaa98bd731431c7d3a7f65e59e7ad076a540f (diff)
downloadgitea-1dfa26e00e8e1ce6f6125335871da1d402a63466.tar.gz
gitea-1dfa26e00e8e1ce6f6125335871da1d402a63466.zip
Move milestone to models/issues/ (#19278)
* Move milestone to models/issues/ * Fix lint * Fix test * Fix lint * Fix lint
Diffstat (limited to 'modules/notification/action')
-rw-r--r--modules/notification/action/action.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/modules/notification/action/action.go b/modules/notification/action/action.go
index bab28db475..547498a9dc 100644
--- a/modules/notification/action/action.go
+++ b/modules/notification/action/action.go
@@ -10,6 +10,7 @@ import (
"strings"
"code.gitea.io/gitea/models"
+ "code.gitea.io/gitea/models/db"
repo_model "code.gitea.io/gitea/models/repo"
user_model "code.gitea.io/gitea/models/user"
"code.gitea.io/gitea/modules/graceful"
@@ -37,7 +38,7 @@ func (a *actionNotifier) NotifyNewIssue(issue *models.Issue, mentions []*user_mo
log.Error("issue.LoadPoster: %v", err)
return
}
- if err := issue.LoadRepo(); err != nil {
+ if err := issue.LoadRepo(db.DefaultContext); err != nil {
log.Error("issue.LoadRepo: %v", err)
return
}
@@ -130,7 +131,7 @@ func (a *actionNotifier) NotifyNewPullRequest(pull *models.PullRequest, mentions
log.Error("pull.LoadIssue: %v", err)
return
}
- if err := pull.Issue.LoadRepo(); err != nil {
+ if err := pull.Issue.LoadRepo(db.DefaultContext); err != nil {
log.Error("pull.Issue.LoadRepo: %v", err)
return
}