fix bug where all repos are returned even when opts.GroupID == 0

This commit is contained in:
☙◦ The Tablet ❀ GamerGirlandCo ◦❧
2026-04-02 20:00:48 -04:00
parent eaee8f07b1
commit 69a36a32e9
+2
View File
@@ -474,6 +474,8 @@ func SearchRepositoryCondition(opts SearchRepoOptions) builder.Cond {
}
if opts.GroupID > 0 {
cond = cond.And(builder.Eq{"`repository`.group_id": opts.GroupID})
} else if opts.GroupID == -1 {
cond = cond.And(builder.Lt{"`repository`.group_id": 1})
}
if opts.Keyword != "" {