evaluator: Format

This commit is contained in:
Simon Bruder 2021-01-04 21:04:16 +01:00
parent 4a9bce07d3
commit 40e58e2557
Signed by: simon
GPG key ID: 8D3C82F9F309F8EC

View file

@ -17,7 +17,7 @@ func main() {
searchQuery := r.URL.Query().Get("query")
searchEngine := r.URL.Query().Get("engine")
if (searchQuery == "" || searchEngine == "") {
if searchQuery == "" || searchEngine == "" {
http.Error(w, "400 Bad Request", http.StatusBadRequest)
return
}
@ -75,7 +75,7 @@ func evaluateBang(searchQuery string, searchEngine string) (query string, engine
bang, query := parseBang(searchQuery)
engine = bangs[bang]
if (bang == "" || engine == ""){
if bang == "" || engine == "" {
return searchQuery, searchEngine
} else {
return query, engine