Skip to content

Commit

Permalink
fix websocket issue (#577)
Browse files Browse the repository at this point in the history
  • Loading branch information
mamantoha authored Jul 8, 2020
1 parent 2e749a2 commit dfe7dca
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/kemal/websocket_handler.cr
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ module Kemal

def call(context : HTTP::Server::Context)
return call_next(context) unless context.ws_route_found? && websocket_upgrade_request?(context)
content = context.websocket.call(context)
context.response.print(content)
context
context.websocket.call(context)
end

def lookup_ws_route(path : String)
Expand Down

0 comments on commit dfe7dca

Please sign in to comment.