chore: types and todos

This commit is contained in:
2023-07-27 20:57:18 -04:00
parent 50c0bfd477
commit 62dc4a51fe
2 changed files with 4 additions and 2 deletions

View File

@@ -11,6 +11,7 @@ export function getRoomByID(id: string): RoomI | null {
}
})
.then((room) => {
//TODO NEED TO FILTER OUT CLAIMCODE REFERENCES
return room;
})
.catch((err) => console.error(err));

View File

@@ -1,13 +1,14 @@
import type { Express } from 'express';
import { PrismaClient } from '@prisma/client';
import { serverConfig } from '../config/serverConfig';
import { pp } from '../utils.js';
import { getRoomByID } from '../data/db';
import { genId } from 'discreetly-interfaces';
// TODO! Properly handle authentication for admin controls
// TODO! Properly handle authentication for admin endpoints
// TODO api endpoint that creates new rooms and generates invite codes for them
export function initEndpoints(app) {
export function initEndpoints(app: Express) {
const prisma = new PrismaClient();
app.get(['/', '/api'], (req, res) => {