Account itself deletable

This commit is contained in:
2024-11-04 19:05:14 +01:00
parent ffccd9f2d4
commit c3d0cc2879
6 changed files with 27 additions and 11 deletions

View File

@@ -139,3 +139,14 @@ account.patch("/", (req: Request, res: Response) => {
})
})
})
account.delete("/:id", (req: Request, res: Response) => {
Account.destroy({
where: {
id: req.params.id
}
})
.then(account => {
res.status(200).send()
})
})