diff options
| author | jwijenbergh <jeroenwijenbergh@protonmail.com> | 2024-05-07 13:26:48 +0200 |
|---|---|---|
| committer | Jeroen Wijenbergh <46386452+jwijenbergh@users.noreply.github.com> | 2024-05-29 14:36:10 +0200 |
| commit | c5c8bcfc53dd4d80133b39c3b130c6600e9cec99 (patch) | |
| tree | 4264920b529d2b8c981995599561ae4d3d7a1635 /internal/discovery | |
| parent | c11a15e8d432584f9c11b67aeb5f9a4b013266c9 (diff) | |
Discovery: Convert the search query to lower
Diffstat (limited to 'internal/discovery')
| -rw-r--r-- | internal/discovery/discovery.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/discovery/discovery.go b/internal/discovery/discovery.go index 6b7b961..fee4e9c 100644 --- a/internal/discovery/discovery.go +++ b/internal/discovery/discovery.go @@ -53,7 +53,7 @@ func (s *Organization) Matches(str string) bool { _, _ = catalog.WriteString(strings.ToLower(v)) _, _ = catalog.WriteString(" ") } - return strings.Contains(catalog.String(), str) + return strings.Contains(catalog.String(), strings.ToLower(str)) } // Servers are the list of servers from https://disco.eduvpn.org/v2/server_list.json @@ -96,7 +96,7 @@ func (s *Server) Matches(str string) bool { _, _ = catalog.WriteString(strings.ToLower(v)) _, _ = catalog.WriteString(" ") } - return strings.Contains(catalog.String(), str) + return strings.Contains(catalog.String(), strings.ToLower(str)) } // Discovery is the main structure used for this package. |
