diff --git a/lib/api.ex b/lib/api.ex index 836087e..07279d2 100644 --- a/lib/api.ex +++ b/lib/api.ex @@ -5,7 +5,7 @@ defmodule Elstat.API.CurrentStatus do data = Elstat.Manager.get_current_state() req = :cowboy_req.reply(200, - %{"content-type" => "text/json"}, + %{"content-type" => "text/json", "Access-Control-Allow-Origin" => "*"}, Poison.encode!(data), req0 ) @@ -20,7 +20,7 @@ defmodule Elstat.API.Status do graph = Elstat.Manager.get_graph_state() req = :cowboy_req.reply(200, - %{"content-type" => "text/json"}, + %{"content-type" => "text/json", "Access-Control-Allow-Origin" => "*"}, Poison.encode!(%{ status: status, graph: graph,