From 98d4b3de53a5eaf412e3b200d4f0ed04c9c4622d Mon Sep 17 00:00:00 2001 From: Ekaterina Vaartis Date: Thu, 18 Apr 2019 20:06:59 +0300 Subject: [PATCH] Treat the manifest path as a file if it doesn't start with http --- lib/mix/tasks/pleroma/emoji.ex | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/mix/tasks/pleroma/emoji.ex b/lib/mix/tasks/pleroma/emoji.ex index fed3dcb40..9cb6fb88d 100644 --- a/lib/mix/tasks/pleroma/emoji.ex +++ b/lib/mix/tasks/pleroma/emoji.ex @@ -231,7 +231,13 @@ defmodule Mix.Tasks.Pleroma.Emoji do end defp fetch_manifest(from) do - Tesla.get!(from).body |> Poison.decode!() + Poison.decode!( + if String.starts_with?(from, "http") do + Tesla.get!(from).body + else + File.read!(from) + end + ) end defp parse_global_opts(args) do -- 2.45.2