mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 23:26:44 +00:00
Change error type to methodNotFoundError
This commit is contained in:
parent
4952d19a6c
commit
8c577d5829
1 changed files with 1 additions and 1 deletions
|
|
@ -162,7 +162,7 @@ func (s *Server) serveSingleRequest(ctx context.Context, codec ServerCodec) {
|
||||||
for _, req := range reqs {
|
for _, req := range reqs {
|
||||||
method := req.Method
|
method := req.Method
|
||||||
if _, found := s.denyList[method]; found {
|
if _, found := s.denyList[method]; found {
|
||||||
resp := errorMessage(&invalidMessageError{fmt.Sprintf("method %s is in deny list", method)})
|
resp := errorMessage(&methodNotFoundError{fmt.Sprintf("method %s is in deny list", method)})
|
||||||
codec.writeJSON(ctx, resp, true)
|
codec.writeJSON(ctx, resp, true)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue