Skip to content

Commit

Permalink
specs
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonyshull committed Feb 10, 2025
1 parent ff45703 commit e08f304
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/dotcom/alerts.ex
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ defmodule Dotcom.Alerts do
@doc """
Does the alert have an effect that is considered service-impacting?
"""
@spec service_impacting_alert?(%Alert{}) :: boolean()
@spec service_impacting_alert?(%Alert.t()) :: boolean()
def service_impacting_alert?(%Alert{effect: effect}) do
effect in @service_impacting_effects
end
Expand Down
4 changes: 2 additions & 2 deletions lib/dotcom/alerts/disruptions/subway.ex
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ defmodule Dotcom.Alerts.Disruptions.Subway do
@doc """
Disruptions that occur any time after today's service range.
"""
@spec future_disruptions() :: %{Utils.ServiceDateTime.service_range() => [%Alert{}]}
@spec future_disruptions() :: %{Utils.ServiceDateTime.service_range() => [Alert.t()]}
def future_disruptions() do
disruption_groups() |> Map.take([:this_week, :next_week, :later])
end

@doc """
Disruptions that occur during today's service range.
"""
@spec todays_disruptions() :: %{Utils.ServiceDateTime.service_range() => [%Alert{}]}
@spec todays_disruptions() :: %{Utils.ServiceDateTime.service_range() => [Alert.t()]}
def todays_disruptions() do
disruption_groups() |> Map.take([:today])
end
Expand Down

0 comments on commit e08f304

Please sign in to comment.