Enable public website sharing.

This commit is contained in:
Mike Cao 2020-08-15 01:17:15 -07:00
parent 48a524e09c
commit 560f1316c1
36 changed files with 294 additions and 61 deletions

View file

@ -1,10 +1,7 @@
import { getMetrics } from 'lib/queries';
import { useAuth } from 'lib/middleware';
import { ok } from 'lib/response';
export default async (req, res) => {
await useAuth(req, res);
const { id, start_at, end_at } = req.query;
const metrics = await getMetrics(+id, new Date(+start_at), new Date(+end_at));