Merge pull request #28 from Chaz6/patch-1

doh-server: change to google.go
This commit is contained in:
Star Brilliant
2018-11-02 10:48:33 +08:00
committed by GitHub
+2 -2
View File
@@ -71,9 +71,9 @@ func (s *Server) parseRequestGoogle(w http.ResponseWriter, r *http.Request) *DNS
cdStr := r.FormValue("cd") cdStr := r.FormValue("cd")
cd := false cd := false
if cdStr == "1" || cdStr == "true" { if cdStr == "1" || strings.EqualFold(cdStr, "true") {
cd = true cd = true
} else if cdStr == "0" || cdStr == "false" || cdStr == "" { } else if cdStr == "0" || strings.EqualFold(cdStr, "false") || cdStr == "" {
} else { } else {
return &DNSRequest{ return &DNSRequest{
errcode: 400, errcode: 400,