mirror of
https://github.com/Portabase/portabase.git
synced 2026-07-14 11:16:13 +02:00
Bug in profile.
This commit is contained in:
@@ -12,7 +12,8 @@ export const LoggedInButton = async () => {
|
|||||||
const currentSession = await getSession();
|
const currentSession = await getSession();
|
||||||
const accounts = await getAccounts();
|
const accounts = await getAccounts();
|
||||||
|
|
||||||
if (!user) return null;
|
// if (!user) return null;
|
||||||
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
@@ -29,11 +30,11 @@ export const LoggedInButton = async () => {
|
|||||||
<SidebarMenuButton>
|
<SidebarMenuButton>
|
||||||
|
|
||||||
<Avatar className="size-6">
|
<Avatar className="size-6">
|
||||||
<AvatarFallback>{user.name[0].toUpperCase()}</AvatarFallback>
|
<AvatarFallback>{user?.name[0].toUpperCase()}</AvatarFallback>
|
||||||
{user.image ? <AvatarImage src={user.image} alt={`${user.name ?? "-"}'s profile picture`} /> : null}
|
{user?.image ? <AvatarImage src={user?.image} alt={`${user.name ?? "-"}'s profile picture`} /> : null}
|
||||||
</Avatar>
|
</Avatar>
|
||||||
|
|
||||||
<span className="first-letter:capitalize">{user.name}</span>
|
<span className="first-letter:capitalize">{user?.name}</span>
|
||||||
<ChevronUp className="ml-auto" />
|
<ChevronUp className="ml-auto" />
|
||||||
</SidebarMenuButton>
|
</SidebarMenuButton>
|
||||||
</LoggedInDropdown>
|
</LoggedInDropdown>
|
||||||
|
|||||||
Reference in New Issue
Block a user