X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=lib%2Fpleroma%2Fweb%2Fxml%2Fxml.ex;h=b3ccf4a55b072bf7834c1679473c1e5c36420aec;hb=816db3f494c6fcc60d0a700dfc473a9cc49c84a0;hp=36430a3faf9379c9f52d332b8e01ff6780b825ef;hpb=76722ea9c8dfbb8fefe247883946aa5c872d9a49;p=akkoma diff --git a/lib/pleroma/web/xml/xml.ex b/lib/pleroma/web/xml/xml.ex index 36430a3fa..b3ccf4a55 100644 --- a/lib/pleroma/web/xml/xml.ex +++ b/lib/pleroma/web/xml/xml.ex @@ -25,9 +25,13 @@ defmodule Pleroma.Web.XML do {doc, _rest} = text |> :binary.bin_to_list() - |> :xmerl_scan.string() + |> :xmerl_scan.string(quiet: true) doc + rescue + _e -> + Logger.debug("Couldn't parse XML: #{inspect(text)}") + :error catch :exit, _error -> Logger.debug("Couldn't parse XML: #{inspect(text)}")