Make like the default
continuous-integration/drone/pr Build was killed Details

Signed-off-by: kolaente <k@knt.li>
This commit is contained in:
kolaente 2020-12-21 23:23:23 +01:00
parent b21afc89ae
commit d89b14ddab
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 1 additions and 3 deletions

View File

@ -219,7 +219,7 @@ func (n *Namespace) ReadAll(a web.Auth, search string, page int, perPage int) (r
)
}
var filterCond builder.Cond
var filterCond builder.Cond = &builder.Like{"namespaces.title", "%" + search + "%"}
vals := strings.Split(search, ",")
ids := []int64{}
for _, val := range vals {
@ -233,8 +233,6 @@ func (n *Namespace) ReadAll(a web.Auth, search string, page int, perPage int) (r
if len(ids) > 0 {
filterCond = builder.In("namespaces.id", ids)
} else {
filterCond = &builder.Like{"namespaces.title", "%" + search + "%"}
}
limit, start := getLimitFromPageIndex(page, perPage)