diff options
Diffstat (limited to 'src/gun_ws.erl')
-rw-r--r-- | src/gun_ws.erl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gun_ws.erl b/src/gun_ws.erl index 86e8524..81682d6 100644 --- a/src/gun_ws.erl +++ b/src/gun_ws.erl @@ -54,7 +54,7 @@ do_check_options([{compress, B}|Opts]) when B =:= true; B =:= false -> do_check_options([{default_protocol, M}|Opts]) when is_atom(M) -> do_check_options(Opts); do_check_options([Opt={protocols, L}|Opts]) when is_list(L) -> - case lists:flatten([[is_binary(B), is_atom(M)] || {B, M} <- L]) of + case lists:usort(lists:flatten([[is_binary(B), is_atom(M)] || {B, M} <- L])) of [true] -> do_check_options(Opts); _ -> {error, {options, {ws, Opt}}} end; |