fix: availability for org team event (#11611)

Co-authored-by: CarinaWolli <wollencarina@gmail.com>
This commit is contained in:
Carina Wollendorfer 2023-09-29 17:56:24 +02:00 committed by GitHub
parent 685be1663e
commit 41b6377f29
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -66,6 +66,8 @@ export const useScheduleForEvent = ({
const pathname = usePathname();
const isTeam = !!event.data?.team?.parentId;
return useSchedule({
username: usernameFromStore ?? username,
eventSlug: eventSlugFromStore ?? eventSlug,
@ -76,6 +78,6 @@ export const useScheduleForEvent = ({
rescheduleUid,
month: monthFromStore ?? month,
duration: durationFromStore ?? duration,
isTeamEvent: pathname.indexOf("/team/") !== -1,
isTeamEvent: pathname.indexOf("/team/") !== -1 || isTeam,
});
};