fix: Cal Video Links Expire After 14 Days (#14557)

* Set expiry date to 14 days after end time

* Add comment
This commit is contained in:
Joe Au-Yeung
2024-04-12 17:05:26 -04:00
committed by GitHub
parent e641bb3d57
commit 902c441248
@@ -107,8 +107,8 @@ const DailyVideoApiAdapter = (): VideoApiAdapter => {
const translateEvent = async (event: CalendarEvent) => {
// Documentation at: https://docs.daily.co/reference#list-rooms
// added a 1 hour buffer for room expiration
const exp = Math.round(new Date(event.endTime).getTime() / 1000) + 60 * 60;
// Adds 14 days from the end of the booking as the expiration date
const exp = Math.round(new Date(event.endTime).getTime() / 1000) + 60 * 60 * 24 * 14;
const { scale_plan: scalePlan } = await getDailyAppKeys();
const hasTeamPlan = await prisma.membership.findFirst({
where: {