Code fixes reported by static code analysis (#450)

This commit is contained in:
V. Elenhaupt 2018-05-17 11:07:40 +03:00 committed by Serdar Dogruyol
parent f3f7e319ae
commit c2236acf3a
14 changed files with 60 additions and 65 deletions

View file

@ -22,8 +22,8 @@ describe "Kemal::WebSocketHandler" do
it "matches on given route" do
handler = Kemal::WebSocketHandler::INSTANCE
ws "/" { |socket, context| socket.send("Match") }
ws "/no_match" { |socket, context| socket.send "No Match" }
ws "/" { |socket| socket.send("Match") }
ws "/no_match" { |socket| socket.send "No Match" }
headers = HTTP::Headers{
"Upgrade" => "websocket",
"Connection" => "Upgrade",
@ -37,7 +37,7 @@ describe "Kemal::WebSocketHandler" do
it "fetches named url parameters" do
handler = Kemal::WebSocketHandler::INSTANCE
ws "/:id" { |s, c| c.params.url["id"] }
ws "/:id" { |_, c| c.params.url["id"] }
headers = HTTP::Headers{
"Upgrade" => "websocket",
"Connection" => "Upgrade",