cosmetic/rich_media/parser: fix typo
This commit is contained in:
parent
4c41f8c286
commit
7998a00346
2 changed files with 3 additions and 3 deletions
|
@ -96,7 +96,7 @@ defp parse_uri(true, url) do
|
|||
|> validate_page_url
|
||||
end
|
||||
|
||||
defp parse_uri(_, _), do: {:error, "not an URL"}
|
||||
defp parse_uri(_, _), do: {:error, "not a URL"}
|
||||
|
||||
defp get_tld(host) do
|
||||
host
|
||||
|
|
|
@ -121,13 +121,13 @@ test "refuses to crawl plain HTTP and other scheme URL" do
|
|||
res = Parser.parse(url)
|
||||
|
||||
assert {:error, {:url, "scheme mismatch"}} == res or
|
||||
{:error, {:url, "not an URL"}} == res
|
||||
{:error, {:url, "not a URL"}} == res
|
||||
end)
|
||||
end
|
||||
|
||||
test "refuses to crawl malformed URLs" do
|
||||
url = "example.com[]/ogp"
|
||||
assert {:error, {:url, "not an URL"}} == Parser.parse(url)
|
||||
assert {:error, {:url, "not a URL"}} == Parser.parse(url)
|
||||
end
|
||||
|
||||
test "refuses to crawl URLs of private network from posts" do
|
||||
|
|
Loading…
Reference in a new issue