update deps, change to compile_env for getting app config

This commit is contained in:
Adam Piontek 2021-04-08 12:01:46 -04:00
parent 42092b6dce
commit ce5aef3239
5 changed files with 240 additions and 280 deletions
lib

View file

@ -7,7 +7,7 @@ defmodule Bones73k do
if it comes from the database, an external API or others.
"""
@app_vars Application.get_env(:bones73k, :app_global_vars, time_zone: "America/New_York")
@app_vars Application.compile_env(:bones73k, :app_global_vars, time_zone: "America/New_York")
@app_time_zone @app_vars[:time_zone]
def app_time_zone, do: @app_time_zone

View file

@ -1,7 +1,7 @@
defmodule Bones73k.Mailer.UserEmail do
import Bamboo.Email
@mailer_vars Application.get_env(:bones73k, :app_global_vars,
@mailer_vars Application.compile_env(:bones73k, :app_global_vars,
mailer_reply_to: "admin@example.com",
mailer_from: {"Bones73k", "bones73k@example.com"}
)