mirror of
https://github.com/wgh136/nysoure.git
synced 2025-09-27 12:17:24 +00:00
Skip empty keywords in search query
This commit is contained in:
@@ -285,6 +285,9 @@ func SearchResource(query string, page int) ([]model.ResourceView, int, error) {
|
||||
temp := make(map[uint]time.Time)
|
||||
first := true
|
||||
for _, keyword := range keywords {
|
||||
if keyword == "" {
|
||||
continue
|
||||
}
|
||||
res, err := searchWithKeyword(keyword)
|
||||
if err != nil {
|
||||
return nil, 0, err
|
||||
|
Reference in New Issue
Block a user