diff options
-rw-r--r-- | README.md | 2 | ||||
-rw-r--r-- | src/cowboy_protocol.erl | 2 | ||||
-rw-r--r-- | src/cowboy_websocket.erl (renamed from src/cowboy_http_websocket.erl) | 2 | ||||
-rw-r--r-- | test/websocket_echo_handler.erl | 2 | ||||
-rw-r--r-- | test/websocket_handler.erl | 2 | ||||
-rw-r--r-- | test/websocket_handler_init_shutdown.erl | 2 | ||||
-rw-r--r-- | test/ws_timeout_hibernate_handler.erl | 2 |
7 files changed, 7 insertions, 7 deletions
@@ -198,7 +198,7 @@ Websocket would look like this: websocket_info/3, websocket_terminate/3]). init({tcp, http}, Req, Opts) -> - {upgrade, protocol, cowboy_http_websocket}. + {upgrade, protocol, cowboy_websocket}. websocket_init(TransportName, Req, _Opts) -> erlang:start_timer(1000, self(), <<"Hello!">>), diff --git a/src/cowboy_protocol.erl b/src/cowboy_protocol.erl index 06f18bb..fc5950a 100644 --- a/src/cowboy_protocol.erl +++ b/src/cowboy_protocol.erl @@ -327,7 +327,7 @@ handler_before_loop(HandlerState, Req, State) -> State2 = handler_loop_timeout(State), handler_loop(HandlerState, Req, State2). -%% Almost the same code can be found in cowboy_http_websocket. +%% Almost the same code can be found in cowboy_websocket. -spec handler_loop_timeout(#state{}) -> #state{}. handler_loop_timeout(State=#state{loop_timeout=infinity}) -> State#state{loop_timeout_ref=undefined}; diff --git a/src/cowboy_http_websocket.erl b/src/cowboy_websocket.erl index f4a774d..fe383c2 100644 --- a/src/cowboy_http_websocket.erl +++ b/src/cowboy_websocket.erl @@ -17,7 +17,7 @@ %% When using websockets, make sure that the crypto application is %% included in your release. If you are not using releases then there %% is no need for concern as crypto is already included. --module(cowboy_http_websocket). +-module(cowboy_websocket). %% API. -export([upgrade/4]). diff --git a/test/websocket_echo_handler.erl b/test/websocket_echo_handler.erl index 949e8a6..926b51d 100644 --- a/test/websocket_echo_handler.erl +++ b/test/websocket_echo_handler.erl @@ -8,7 +8,7 @@ websocket_info/3, websocket_terminate/3]). init(_Any, _Req, _Opts) -> - {upgrade, protocol, cowboy_http_websocket}. + {upgrade, protocol, cowboy_websocket}. handle(_Req, _State) -> exit(badarg). diff --git a/test/websocket_handler.erl b/test/websocket_handler.erl index 1430890..caf4828 100644 --- a/test/websocket_handler.erl +++ b/test/websocket_handler.erl @@ -8,7 +8,7 @@ websocket_info/3, websocket_terminate/3]). init(_Any, _Req, _Opts) -> - {upgrade, protocol, cowboy_http_websocket}. + {upgrade, protocol, cowboy_websocket}. handle(_Req, _State) -> exit(badarg). diff --git a/test/websocket_handler_init_shutdown.erl b/test/websocket_handler_init_shutdown.erl index 371c34b..5fdfba3 100644 --- a/test/websocket_handler_init_shutdown.erl +++ b/test/websocket_handler_init_shutdown.erl @@ -8,7 +8,7 @@ websocket_info/3, websocket_terminate/3]). init(_Any, _Req, _Opts) -> - {upgrade, protocol, cowboy_http_websocket}. + {upgrade, protocol, cowboy_websocket}. handle(_Req, _State) -> exit(badarg). diff --git a/test/ws_timeout_hibernate_handler.erl b/test/ws_timeout_hibernate_handler.erl index 871a686..ac6ee4f 100644 --- a/test/ws_timeout_hibernate_handler.erl +++ b/test/ws_timeout_hibernate_handler.erl @@ -8,7 +8,7 @@ websocket_info/3, websocket_terminate/3]). init(_Any, _Req, _Opts) -> - {upgrade, protocol, cowboy_http_websocket}. + {upgrade, protocol, cowboy_websocket}. handle(_Req, _State) -> exit(badarg). |