MastodonAPI.StatusView: comment out unused build_image_url/2
This commit is contained in:
parent
6521155335
commit
bef32d6e02
1 changed files with 14 additions and 14 deletions
|
@ -558,18 +558,18 @@ defp build_application(_), do: nil
|
||||||
# Avoid applying URI.merge unless necessary
|
# Avoid applying URI.merge unless necessary
|
||||||
# TODO: revert to always attempting URI.merge(image_url_data, page_url_data)
|
# TODO: revert to always attempting URI.merge(image_url_data, page_url_data)
|
||||||
# when Elixir 1.12 is the minimum supported version
|
# when Elixir 1.12 is the minimum supported version
|
||||||
@spec build_image_url(struct() | nil, struct()) :: String.t() | nil
|
# @spec build_image_url(struct() | nil, struct()) :: String.t() | nil
|
||||||
defp build_image_url(
|
# defp build_image_url(
|
||||||
%URI{scheme: image_scheme, host: image_host} = image_url_data,
|
# %URI{scheme: image_scheme, host: image_host} = image_url_data,
|
||||||
%URI{} = _page_url_data
|
# %URI{} = _page_url_data
|
||||||
)
|
# )
|
||||||
when not is_nil(image_scheme) and not is_nil(image_host) do
|
# when not is_nil(image_scheme) and not is_nil(image_host) do
|
||||||
image_url_data |> to_string
|
# image_url_data |> to_string
|
||||||
end
|
# end
|
||||||
|
#
|
||||||
defp build_image_url(%URI{} = image_url_data, %URI{} = page_url_data) do
|
# defp build_image_url(%URI{} = image_url_data, %URI{} = page_url_data) do
|
||||||
URI.merge(page_url_data, image_url_data) |> to_string
|
# URI.merge(page_url_data, image_url_data) |> to_string
|
||||||
end
|
# end
|
||||||
|
#
|
||||||
defp build_image_url(_, _), do: nil
|
# defp build_image_url(_, _), do: nil
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue