refactor: remove db read on focus for groups view
This commit is contained in:
parent
3c79d044d4
commit
ec814a8c94
1 changed files with 1 additions and 5 deletions
|
|
@ -431,11 +431,7 @@ defmodule MvWeb.GroupLive.Show do
|
|||
# Add Member Events
|
||||
@impl true
|
||||
def handle_event("show_add_member_input", _params, socket) do
|
||||
# Reload group to ensure we have the latest members list
|
||||
actor = current_actor(socket)
|
||||
group = socket.assigns.group
|
||||
socket = reload_group(socket, group.slug, actor)
|
||||
|
||||
# Use existing @group from assigns; no DB read on focus. Reload only on commit (add/remove).
|
||||
{:noreply,
|
||||
socket
|
||||
|> assign(:show_add_member_input, true)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue