fix: replace Mix.env() with Application.get_env() for production compatibility
Mix is not available in production releases. Use Application.get_env/3 to check environment at runtime instead of Mix.env().
This commit is contained in:
parent
4cf39e66a6
commit
4b11f74e39
1 changed files with 1 additions and 1 deletions
|
|
@ -283,7 +283,7 @@ defmodule ToweropsWeb.DeviceLive.Index do
|
|||
end
|
||||
|
||||
defp tick_interval_ms do
|
||||
if Mix.env() == :test, do: :infinity, else: to_timeout(second: 15)
|
||||
if Application.get_env(:towerops, :env) == :test, do: :infinity, else: to_timeout(second: 15)
|
||||
end
|
||||
|
||||
defp schedule_tick do
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue