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 dcc6c2b commit a34862aCopy full SHA for a34862a
models/issues/review_list.go
@@ -108,11 +108,7 @@ func (opts *FindReviewOptions) toCond() builder.Cond {
108
cond = cond.And(builder.Eq{"reviewer_id": opts.ReviewerID})
109
}
110
if len(opts.Types) > 0 {
111
- typeConds := make([]builder.Cond, 0, len(opts.Types))
112
- for _, reviewType := range opts.Types {
113
- typeConds = append(typeConds, builder.Eq{"type": reviewType})
114
- }
115
- cond = cond.And(builder.Or(typeConds...))
+ cond = cond.And(builder.In("type", opts.Types))
116
117
if opts.OfficialOnly {
118
cond = cond.And(builder.Eq{"official": true})
0 commit comments