We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 12960b9 commit dac4fbcCopy full SHA for dac4fbc
models/notification.go
@@ -103,7 +103,11 @@ func (opts *FindNotificationOptions) ToCond() builder.Cond {
103
104
// ToSession will convert the given options to a xorm Session by using the conditions from ToCond and joining with issue table if required
105
func (opts *FindNotificationOptions) ToSession(e Engine) *xorm.Session {
106
- return opts.setSessionPagination(e.Where(opts.ToCond()))
+ sess := e.Where(opts.ToCond())
107
+ if opts.Page != 0 {
108
+ sess = opts.setSessionPagination(sess)
109
+ }
110
+ return sess
111
}
112
113
func getNotifications(e Engine, options FindNotificationOptions) (nl NotificationList, err error) {
0 commit comments