Skip to content

armgit / umami

Public Imported from GitHub
0

Umami is a privacy-first web and product analytics platform. Traffic, campaigns, behavior, conversions, and revenue in one place. No cookies, no surveillance, self-hosted or in the cloud.

Fix getWebsites call.

Mike Cao2b10802e07fd
diff --git a/pages/api/realtime/init.ts b/pages/api/realtime/init.ts
index b1d1f32f7..70aab0ebc 100644
--- a/pages/api/realtime/init.ts
+++ b/pages/api/realtime/init.ts
@@ -13,7 +13,7 @@ export default async (req: NextApiRequestAuth, res: NextApiResponse<RealtimeInit
if (req.method === 'GET') {
const { id: userId } = req.auth.user;
- const websites = await getUserWebsites(userId);
+ const websites = await getUserWebsites({ userId });
const ids = websites.map(({ id }) => id);
const token = createToken({ websites: ids }, secret());
const data = await getRealtimeData(ids, subMinutes(new Date(), 30));