From: Roger Braun Date: Fri, 8 Sep 2017 07:08:31 +0000 (+0200) Subject: Try to fetch from html again if fetching from atom gives no results. X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=95aa6a3c651fed9810889d3446f2a1d710efb55e;p=akkoma Try to fetch from html again if fetching from atom gives no results. --- diff --git a/lib/pleroma/web/ostatus/ostatus.ex b/lib/pleroma/web/ostatus/ostatus.ex index 3e2acdd0f..fa8c086d6 100644 --- a/lib/pleroma/web/ostatus/ostatus.ex +++ b/lib/pleroma/web/ostatus/ostatus.ex @@ -299,7 +299,7 @@ defmodule Pleroma.Web.OStatus do end def fetch_activity_from_url(url) do - with {:ok, activities} <- fetch_activity_from_atom_url(url) do + with {:ok, activities} when length(activities) > 0 <- fetch_activity_from_atom_url(url) do {:ok, activities} else _e -> with {:ok, activities} <- fetch_activity_from_html_url(url) do