瀏覽代碼

Limit before slots to 5

theenglishway (time) 4 年之前
父節點
當前提交
0d89cfe760
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lib/vaccins_web/live/location_component.ex

+ 1 - 1
lib/vaccins_web/live/location_component.ex

@@ -103,7 +103,7 @@ defmodule VaccinsWeb.LocationComponent do
        do:
          assigns
          |> Map.put(:slots_after, after_slots |> Enum.take(5))
-         |> Map.put(:slots_before, before_slots)
+         |> Map.put(:slots_before, before_slots |> Enum.take(5))
          |> Map.put(:last_early_slot_seen, DateTime.utc_now())
 
   defp integrate_availabilities(assigns), do: assigns