fix module aliasing issues

This commit is contained in:
2026-05-05 23:04:01 +01:00
parent 0a7ad6af8a
commit 11396e37a8
11 changed files with 43 additions and 22 deletions
@@ -51,7 +51,12 @@
<h2 class="text-2xl font-display font-semibold">QWAN</h2>
<div class="space-y-4 text-lg leading-relaxed text-base-content/80">
<p>
I'm a partner at <a href="https://qwan.eu" class="text-primary hover:underline" target="_blank" rel="noopener">QWAN</a>,
I'm a partner at <a
href="https://qwan.eu"
class="text-primary hover:underline"
target="_blank"
rel="noopener"
>QWAN</a>,
where we build software based on user needs, and help others do the same, and learn together. If you're looking for collaboration, have a product you want to build, a service that needs improvement,
or just want to nerd out about agentic systems, feel free to reach out.
</p>
@@ -13,7 +13,7 @@
rel="noopener"
>QWAN</a>.
This is where I write about agentic engineering, wishcraft, naive evals,
and whatever prototype I'm building this week.
and whatever prototype I'm building this week.
</p>
</div>
</section>
+10 -8
View File
@@ -251,14 +251,16 @@ defmodule FirehoseWeb.UserAuth do
defp mount_current_scope(socket, session) do
Phoenix.Component.assign_new(socket, :current_scope, fn ->
if token = session["user_token"] do
case Accounts.get_user_by_session_token(token) do
{user, _token_inserted_at} -> Scope.for_user(user)
nil -> Scope.for_user(nil)
end
else
Scope.for_user(nil)
end
scope_from_session(session)
end)
end
defp scope_from_session(%{"user_token" => token}) do
case Accounts.get_user_by_session_token(token) do
{user, _token_inserted_at} -> Scope.for_user(user)
nil -> Scope.for_user(nil)
end
end
defp scope_from_session(_session), do: Scope.for_user(nil)
end