diff --git a/apps/parse/lib/parse/alerts.ex b/apps/parse/lib/parse/alerts.ex index 736bafc0..7cc95059 100644 --- a/apps/parse/lib/parse/alerts.ex +++ b/apps/parse/lib/parse/alerts.ex @@ -6,6 +6,7 @@ defmodule Parse.Alerts do the basic field set. """ + require Logger use Timex alias Model.Alert @@ -75,6 +76,11 @@ defmodule Parse.Alerts do copy(cause) end + defp cause(alert) do + Logger.error("No cause found in alert: #{inspect(alert)}") + "" + end + def lifecycle("ONGOING"), do: "ONGOING" def lifecycle("UPCOMING"), do: "UPCOMING" def lifecycle(<<"UPCOMING", _::binary-1, "ONGOING">>), do: "ONGOING_UPCOMING"