diff options
author | Andrey Nering <andrey.nering@gmail.com> | 2017-04-01 09:58:20 -0300 |
---|---|---|
committer | Andrey Nering <andrey.nering@gmail.com> | 2017-04-01 09:58:20 -0300 |
commit | e5c56fe30ddfe2ea5b065a286cb467a914d044e8 (patch) | |
tree | c585b8d651d651f6c123b7e401ddd128018169f4 /models/issue_watch.go | |
parent | e6781d5488849d9415abc2402e914259214a13c4 (diff) | |
download | gitea-e5c56fe30ddfe2ea5b065a286cb467a914d044e8.tar.gz gitea-e5c56fe30ddfe2ea5b065a286cb467a914d044e8.zip |
Code style fixes
Diffstat (limited to 'models/issue_watch.go')
-rw-r--r-- | models/issue_watch.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/models/issue_watch.go b/models/issue_watch.go index 8262ae2ea1..37511787e5 100644 --- a/models/issue_watch.go +++ b/models/issue_watch.go @@ -71,9 +71,9 @@ func CreateOrUpdateIssueWatch(userID, issueID int64, isWatching bool) error { // GetIssueWatch returns an issue watch by user and issue func GetIssueWatch(userID, issueID int64) (iw *IssueWatch, exists bool, err error) { - iw, exists, err = getIssueWatch(x, userID, issueID) - return + return getIssueWatch(x, userID, issueID) } + func getIssueWatch(e Engine, userID, issueID int64) (iw *IssueWatch, exists bool, err error) { iw = new(IssueWatch) exists, err = e. @@ -87,6 +87,7 @@ func getIssueWatch(e Engine, userID, issueID int64) (iw *IssueWatch, exists bool func GetIssueWatchers(issueID int64) ([]*IssueWatch, error) { return getIssueWatchers(x, issueID) } + func getIssueWatchers(e Engine, issueID int64) (watches []*IssueWatch, err error) { err = e. Where("issue_id = ?", issueID). |