adding connection now works

This commit is contained in:
Puyodead1
2023-03-18 19:15:40 -04:00
parent 21bfda32e4
commit 6a52e65e27
13 changed files with 54 additions and 41 deletions
@@ -6,7 +6,7 @@ import { route } from "../../../util";
const router = Router();
router.get("/", route({}), async (req: Request, res: Response) => {
const { connection_id: connection_name } = req.params;
const { connection_name } = req.params;
const connection = ConnectionStore.connections.get(connection_name);
if (!connection)
throw FieldErrors({
@@ -13,7 +13,7 @@ router.post(
"/",
route({ body: "ConnectionCallbackSchema" }),
async (req: Request, res: Response) => {
const { connection_id: connection_name } = req.params;
const { connection_name } = req.params;
const connection = ConnectionStore.connections.get(connection_name);
if (!connection)
throw FieldErrors({