live_beats/lib/live_beats_web/live/nav.ex
2021-11-12 10:10:04 -05:00

9 lines
243 B
Elixir

defmodule LiveBeatsWeb.Nav do
import Phoenix.LiveView
alias LiveBeats.MediaLibrary
def on_mount(:default, _params, _session, socket) do
{:cont, assign(socket, :active_users, MediaLibrary.list_active_profiles(limit: 20))}
end
end