Skip to content

Commit

Permalink
feat: profile editing
Browse files Browse the repository at this point in the history
  • Loading branch information
Cyro292 authored and BehsadRiemer committed May 18, 2024
1 parent 43e01c0 commit bb27269
Show file tree
Hide file tree
Showing 17 changed files with 1,033 additions and 81 deletions.
7 changes: 6 additions & 1 deletion app/profile/[profile_id]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@ export default async function ProfilePage({
where: { id: params.profile_id },
include: { profile: true },
});
const profileId = user?.profile.at(0)?.id;

const contacts = await db.contact.findMany({
where: { profileId: profileId },
});

if (!user) {
return (
Expand All @@ -29,5 +34,5 @@ export default async function ProfilePage({
);
}

return <ProfileOverview user={user} />;
return <ProfileOverview user={user} contacts={contacts} />;
}
Loading

0 comments on commit bb27269

Please sign in to comment.