Skip to content

Commit 7eb7516

Browse files
committed
fix: ensure previewed user is not nil
1 parent df599c3 commit 7eb7516

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/algora_web/live/org/dashboard_live.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ defmodule AlgoraWeb.Org.DashboardLive do
4848
defp get_previewed_user(%{last_context: "repo/" <> repo} = current_org) do
4949
case String.split(repo, "/") do
5050
[repo_owner, _repo_name] ->
51-
Repo.one(from u in User, where: u.provider_login == ^repo_owner and not is_nil(u.handle))
51+
Repo.one(from u in User, where: u.provider_login == ^repo_owner and not is_nil(u.handle)) || current_org
5252

5353
_ ->
5454
current_org

0 commit comments

Comments
 (0)