mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 20:30:23 +00:00
Fix a confusing code snippet
Reported by Jordan Chaitin.
This commit is contained in:
parent
ec00e3d60e
commit
47eaadb209
1 changed files with 2 additions and 1 deletions
|
@ -216,6 +216,7 @@ list used by routing. This will apply to all new connections accepted
|
|||
by the listener:
|
||||
|
||||
[source,erlang]
|
||||
cowboy:set_env(my_http_listener, dispatch, cowboy_router:compile(Dispatch)).
|
||||
Dispatch = cowboy_router:compile(Routes),
|
||||
cowboy:set_env(my_http_listener, dispatch, Dispatch).
|
||||
|
||||
Note that you need to compile the routes again before updating.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue