mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-12-05 00:57:59 +01:00
7 lines
168 B
Elixir
7 lines
168 B
Elixir
defmodule PhilomenaWeb.BanView do
|
|
use PhilomenaWeb, :view
|
|
|
|
def active?(ban) do
|
|
ban.enabled and DateTime.diff(ban.valid_until, DateTime.utc_now()) > 0
|
|
end
|
|
end
|