forked from cerc-io/plugeth
all: use http package to replace http method names (#26535)
This commit is contained in:
+1
-1
@@ -48,7 +48,7 @@ func errorJSON(msg string) []byte {
|
||||
}
|
||||
|
||||
func (h GraphiQL) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||
if r.Method != "GET" {
|
||||
if r.Method != http.MethodGet {
|
||||
respond(w, errorJSON("only GET requests are supported"), http.StatusMethodNotAllowed)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user