mirror of
https://framagit.org/framasoft/mobilizon.git
synced 2024-12-26 01:38:36 +00:00
Don't add empty search parameters to global search engine
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
ac7b994b6f
commit
76ff11ceae
1 changed files with 2 additions and 2 deletions
|
@ -70,7 +70,7 @@ defmodule Mobilizon.Service.GlobalSearch.SearchMobilizon do
|
|||
:count,
|
||||
:sortBy
|
||||
])
|
||||
|> Keyword.reject(fn {_key, val} -> is_nil(val) end)
|
||||
|> Keyword.reject(fn {_key, val} -> is_nil(val) or val == "" end)
|
||||
|
||||
events_url = "#{search_endpoint()}#{@search_events_api}?#{encode(options)}"
|
||||
Logger.debug("Calling global search engine url #{events_url}")
|
||||
|
@ -117,7 +117,7 @@ defmodule Mobilizon.Service.GlobalSearch.SearchMobilizon do
|
|||
:bbox,
|
||||
:sortBy
|
||||
])
|
||||
|> Keyword.reject(fn {_key, val} -> is_nil(val) end)
|
||||
|> Keyword.reject(fn {_key, val} -> is_nil(val) or val == "" end)
|
||||
|
||||
groups_url = "#{search_endpoint()}#{@search_groups_api}?#{encode(options)}"
|
||||
Logger.debug("Calling global search engine url #{groups_url}")
|
||||
|
|
Loading…
Reference in a new issue