aboutsummaryrefslogtreecommitdiffstats
path: root/models/notification.go
diff options
context:
space:
mode:
Diffstat (limited to 'models/notification.go')
-rw-r--r--models/notification.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/models/notification.go b/models/notification.go
index 8f5d9d01e6..b53d236e43 100644
--- a/models/notification.go
+++ b/models/notification.go
@@ -498,14 +498,15 @@ func (n *Notification) APIURL() string {
type NotificationList []*Notification
// LoadAttributes load Repo Issue User and Comment if not loaded
-func (nl NotificationList) LoadAttributes() (err error) {
+func (nl NotificationList) LoadAttributes() error {
+ var err error
for i := 0; i < len(nl); i++ {
err = nl[i].LoadAttributes()
if err != nil && !IsErrCommentNotExist(err) {
- return
+ return err
}
}
- return
+ return nil
}
func (nl NotificationList) getPendingRepoIDs() []int64 {