Fix return response and add list

This commit is contained in:
Owen Schwartz 2024-10-02 21:17:38 -04:00
parent e85c94d21d
commit ecdf2dfd04
No known key found for this signature in database
GPG key ID: 8271FDFFD9E0CCBD
22 changed files with 354 additions and 17 deletions

View file

@ -32,7 +32,7 @@ export async function createTarget(req: Request, res: Response, next: NextFuncti
const newTarget = await db.insert(targets).values(targetData).returning();
return res.status(HttpCode.CREATED).send(
response({
response(res, {
data: newTarget[0],
success: true,
error: false,