removes overly restrictive guards

This commit is contained in:
alisdair sullivan 2011-11-29 21:11:17 -08:00
parent 0035cd67a7
commit 726838cfff
2 changed files with 2 additions and 4 deletions

View file

@ -38,8 +38,7 @@
-spec to_json(Source::(binary() | list()), Opts::opts()) -> binary().
to_json(Source, Opts) when (is_binary(Source) andalso is_list(Opts))
orelse (is_list(Source) andalso is_list(Opts)) ->
to_json(Source, Opts) when is_list(Opts) ->
(gen_json:parser(?MODULE, Opts, jsx_utils:extract_opts(Opts)))(Source).

View file

@ -36,8 +36,7 @@
-spec to_term(Source::(binary() | list()), Opts::opts()) -> binary().
to_term(Source, Opts) when (is_binary(Source) andalso is_list(Opts))
orelse (is_list(Source) andalso is_list(Opts)) ->
to_term(Source, Opts) when is_list(Opts) ->
(gen_json:parser(?MODULE, Opts, jsx_utils:extract_opts(Opts)))(Source).