Skip to content

Commit

Permalink
add winner to ui
Browse files Browse the repository at this point in the history
  • Loading branch information
minhd-vu committed Feb 26, 2024
1 parent fc95dc0 commit ce3373c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions components/Party.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ export default function Party() {

return (
<PartyCard code={party.code}>
{party.winner && <h2>Last Round's Winner: {party.winner.name}</h2>}
<h2>Mode: {_.startCase(_.toLower(party.mode))}</h2>
{!isAdmin && (
<p className="text-sm">
Expand Down
1 change: 1 addition & 0 deletions lib/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export async function getUser(email: string) {
party: {
include: {
players: true,
winner: true,
},
},
},
Expand Down

0 comments on commit ce3373c

Please sign in to comment.