Skip to content

Commit

Permalink
use new isLoggedInUser from ssr instead of client
Browse files Browse the repository at this point in the history
  • Loading branch information
sean-brydon committed Jan 21, 2025
1 parent 4fe51a9 commit 7304b98
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ export async function getServerSideProps(context: GetServerSidePropsContext) {
userTimeFormat,
requiresLoginToUpdate,
rescheduledToUid,
isLoggedInUserHost,
},
};
}
2 changes: 1 addition & 1 deletion apps/web/modules/bookings/views/bookings-single-view.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ export default function Success(props: PageProps) {
props?.userTimeFormat ? props.userTimeFormat === 24 : isBrowserLocale24h()
);
const { data: session } = useSession();
const isHost = bookingInfo?.user?.id === session?.user?.id;
const isHost = props.isLoggedInUserHost;

const [date, setDate] = useState(dayjs.utc(bookingInfo.startTime));

Expand Down

0 comments on commit 7304b98

Please sign in to comment.