@@ -29,7 +29,7 @@ def call(service, service_method, env)
2929 request = GRPCWeb ::GRPCWebRequest . new ( service , service_method , content_type , accept , body )
3030 response = GRPCWeb ::GRPCRequestProcessor . process ( request )
3131
32- [ 200 , { 'Content-Type ' => response . content_type } , [ response . body ] ]
32+ [ 200 , { 'content-type ' => response . content_type } , [ response . body ] ]
3333 rescue Google ::Protobuf ::ParseError => e
3434 invalid_response ( e . message )
3535 rescue StandardError => e
@@ -51,27 +51,27 @@ def valid_content_types?(rack_request)
5151 def not_found_response ( path )
5252 [
5353 NOT_FOUND ,
54- { 'Content-Type ' => 'text/plain' , 'X-Cascade ' => 'pass' } ,
54+ { 'content-type ' => 'text/plain' , 'x-cascade ' => 'pass' } ,
5555 [ "Not Found: #{ path } " ] ,
5656 ]
5757 end
5858
5959 def unsupported_media_type_response
6060 [
6161 UNSUPPORTED_MEDIA_TYPE ,
62- { 'Content-Type ' => 'text/plain' } ,
62+ { 'content-type ' => 'text/plain' } ,
6363 [ 'Unsupported Media Type: Invalid Content-Type or Accept header' ] ,
6464 ]
6565 end
6666
6767 def invalid_response ( message )
68- [ 422 , { 'Content-Type ' => 'text/plain' } , [ "Invalid request format: #{ message } " ] ]
68+ [ 422 , { 'content-type ' => 'text/plain' } , [ "Invalid request format: #{ message } " ] ]
6969 end
7070
7171 def error_response
7272 [
7373 INTERNAL_SERVER_ERROR ,
74- { 'Content-Type ' => 'text/plain' } ,
74+ { 'content-type ' => 'text/plain' } ,
7575 [ 'Request failed with an unexpected error.' ] ,
7676 ]
7777 end
0 commit comments