Browse Source

Fix a websocket test handler that was throwing an unwanted error

The test still worked because we expect the websocket connection
to fail, but it didn't fail exactly the way we wanted it to.
Loïc Hoguin 13 years ago
parent
commit
ad87fee0af
1 changed files with 1 additions and 1 deletions
  1. 1 1
      test/websocket_handler_init_shutdown.erl

+ 1 - 1
test/websocket_handler_init_shutdown.erl

@@ -17,7 +17,7 @@ terminate(_Req, _State) ->
 	exit(badarg).
 
 websocket_init(_TransportName, Req, _Opts) ->
-	Req2 = cowboy_http_req:reply(403, Req),
+	{ok, Req2} = cowboy_http_req:reply(403, Req),
 	{shutdown, Req2}.
 
 websocket_handle(_Frame, _Req, _State) ->