parent
1546bb6a39
commit
d396d59779
|
|
@ -70,8 +70,9 @@ parse(Uri, DefaultVHost) ->
|
|||
error:Err -> {error, {Err, Uri}}
|
||||
end.
|
||||
|
||||
parse1(Uri, DefaultVHost) when is_list(Uri) ->
|
||||
case uri_parser:parse(Uri, [{host, undefined}, {path, undefined},
|
||||
parse1(Uri, DefaultVHost) when is_list(Uri); is_binary(Uri) ->
|
||||
UriString = rabbit_data_coercion:to_list(Uri),
|
||||
case uri_parser:parse(UriString, [{host, undefined}, {path, undefined},
|
||||
{port, undefined}, {'query', []}]) of
|
||||
{error, Err} ->
|
||||
throw({unable_to_parse_uri, Err});
|
||||
|
|
|
|||
|
|
@ -40,7 +40,8 @@
|
|||
%% 'fragment'.
|
||||
|
||||
parse(AbsURI, Defaults) ->
|
||||
case parse_scheme(AbsURI) of
|
||||
AbsUriString = rabbit_data_coercion:to_list(AbsURI),
|
||||
case parse_scheme(AbsUriString) of
|
||||
{error, Reason} ->
|
||||
{error, Reason};
|
||||
{Scheme, Rest} ->
|
||||
|
|
|
|||
Loading…
Reference in New Issue