aboutsummaryrefslogtreecommitdiffstats
path: root/src/cowboy_handler.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/cowboy_handler.erl')
-rw-r--r--src/cowboy_handler.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cowboy_handler.erl b/src/cowboy_handler.erl
index fd2e085..ab09a97 100644
--- a/src/cowboy_handler.erl
+++ b/src/cowboy_handler.erl
@@ -53,9 +53,9 @@
execute(Req, Env) ->
{_, Handler} = lists:keyfind(handler, 1, Env),
{_, HandlerOpts} = lists:keyfind(handler_opts, 1, Env),
- case lists:keyfind(loop_max_buffer, 1, Env) of
- false -> MaxBuffer = 5000, ok;
- {_, MaxBuffer} -> ok
+ MaxBuffer = case lists:keyfind(loop_max_buffer, 1, Env) of
+ false -> 5000;
+ {_, MaxBuffer0} -> MaxBuffer0
end,
handler_init(Req, #state{env=Env, loop_max_buffer=MaxBuffer},
Handler, HandlerOpts).