There was an error while loading. Please reload this page.
1 parent e456fae commit 208f05dCopy full SHA for 208f05d
1 file changed
dev/notifier.ex
@@ -2,18 +2,16 @@ defmodule Demo.BlobNotifier do
2
@moduledoc false
3
use Ash.Notifier
4
5
- @impl true
6
- def notify(%Ash.Notifier.Notification{action: %{name: :run_pending_analyzers}} = notification) do
7
if Code.ensure_loaded?(Phoenix.PubSub) do
8
- Phoenix.PubSub.broadcast(
9
- Demo.PubSub,
10
- "blob_analysis",
11
- {:analysis_complete, notification.data}
12
- )
13
- else
14
- :ok
+ @impl true
+ def notify(%Ash.Notifier.Notification{action: %{name: :run_pending_analyzers}} = notification) do
+ Phoenix.PubSub.broadcast(
+ Demo.PubSub,
+ "blob_analysis",
+ {:analysis_complete, notification.data}
+ )
+ end
15
end
16
- end
17
18
def notify(_), do: :ok
19
0 commit comments