diff --git a/src/shapes/VideoChatShapeUtil.tsx b/src/shapes/VideoChatShapeUtil.tsx index 7097054..c3d264d 100644 --- a/src/shapes/VideoChatShapeUtil.tsx +++ b/src/shapes/VideoChatShapeUtil.tsx @@ -57,7 +57,7 @@ export class VideoChatShape extends BaseBoxShapeUtil { return props; } - async generateMeetingToken(roomName: string, isOwner: boolean = false) { + async generateMeetingToken(roomName: string) { const workerUrl = import.meta.env.VITE_TLDRAW_WORKER_URL; const apiKey = import.meta.env.VITE_DAILY_API_KEY; @@ -167,7 +167,7 @@ export class VideoChatShape extends BaseBoxShapeUtil { // Generate meeting token for the owner // First ensure the room exists, then generate token - const meetingToken = await this.generateMeetingToken(roomName, true); + const meetingToken = await this.generateMeetingToken(roomName); // Store the room URL and token in localStorage localStorage.setItem(storageKey, url); diff --git a/worker/worker.ts b/worker/worker.ts index b60d760..29f7afe 100644 --- a/worker/worker.ts +++ b/worker/worker.ts @@ -173,7 +173,7 @@ const router = AutoRouter({ } try { - const body = await req.json() + const body = await req.json() as { room_name: string; properties: any }; const response = await fetch('https://api.daily.co/v1/meeting-tokens', { method: 'POST', headers: { @@ -381,7 +381,7 @@ const router = AutoRouter({ } try { - const body = await req.json() + const body = await req.json() as any; const response = await fetch('https://api.daily.co/v1/recordings', { method: 'POST', headers: {