I have a pretty standard show.ex from the generators:
defmodule AppWeb.TaskLive.Show do
use AppWeb, :live_view
alias App.Tasks
@impl true
def mount(_params, _session, socket) do
{:ok, socket}
end
@impl true
def handle_params(%{"id" => id}, _, socket) do
{:noreply,
socket
|> assign(:page_title, page_title(socket.assigns.live_action))
|> assign(:task, Tasks.get_task!(id))}
end
defp page_title(:show), do: "Show Task"
defp page_title(:edit), do: "Edit Task"
end
A message is being sent to it by a form component on save and edit:
defp notify_parent(msg), do: send(self(), {__MODULE__, msg})
But there is no error thrown, even though there is no handle_info defined in the live view. Is there a handle_info automatically defined somewhere in Phoenix? Any documentation of this behavior I could look at?
Something changed in the develop branch and now it’s giving the expected error of no function clause matching in TaskLive.Show. Can’t seem to figure out why it’s working on main, as the handle_info is not there.
Thank you!