diff options
author | Ethan Koenig <etk39@cornell.edu> | 2017-02-08 22:47:24 -0500 |
---|---|---|
committer | Lunny Xiao <xiaolunwen@gmail.com> | 2017-02-09 11:47:24 +0800 |
commit | e6b4448ba373a5346dc54332980f3f56320bb0c6 (patch) | |
tree | e0fc49e8f64833232b0cfe8fdccae98ed19e6b41 /models | |
parent | e4031b822ac358c1554a335016674fbd1d2a61f9 (diff) | |
download | gitea-e6b4448ba373a5346dc54332980f3f56320bb0c6.tar.gz gitea-e6b4448ba373a5346dc54332980f3f56320bb0c6.zip |
Fix bug in Issue.GetIsRead (#876)
Diffstat (limited to 'models')
-rw-r--r-- | models/issue.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/models/issue.go b/models/issue.go index 7cbb5bb5f8..97c633c234 100644 --- a/models/issue.go +++ b/models/issue.go @@ -193,7 +193,8 @@ func (issue *Issue) GetIsRead(userID int64) error { if has, err := x.Get(issueUser); err != nil { return err } else if !has { - return ErrUserNotExist{UID: userID} + issue.IsRead = false + return nil } issue.IsRead = issueUser.IsRead return nil |