From 8b0b41186a182cd66912a78353d3092da0fa014c Mon Sep 17 00:00:00 2001 From: Kieran Eglin Date: Thu, 23 May 2024 10:28:08 -0700 Subject: [PATCH] Added code comments --- .../controllers/sources/source_html/media_item_table_live.ex | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/pinchflat_web/controllers/sources/source_html/media_item_table_live.ex b/lib/pinchflat_web/controllers/sources/source_html/media_item_table_live.ex index 7e732c1..48e766c 100644 --- a/lib/pinchflat_web/controllers/sources/source_html/media_item_table_live.ex +++ b/lib/pinchflat_web/controllers/sources/source_html/media_item_table_live.ex @@ -74,6 +74,8 @@ defmodule Pinchflat.Sources.MediaItemTableLive do {:noreply, assign(socket, new_assigns)} end + # This, along with the handle_info below, is a pattern to reload _all_ + # tables on page rather than just the one that triggered the reload. def handle_event("reload_page", _params, socket) do PinchflatWeb.Endpoint.broadcast("media_table", "reload", nil)