Remove API routes for removing all items and purging media progress

This commit is contained in:
advplyr 2023-07-09 14:07:30 -05:00
parent f73a0cce72
commit f4497acd48
16 changed files with 1 additions and 74 deletions

View file

@ -441,20 +441,6 @@ class LibraryItemController {
}
}
// DELETE: api/items/all
// TODO: Remove
async deleteAll(req, res) {
return res.sendStatus(404)
// if (!req.user.isAdminOrUp) {
// Logger.warn('User other than admin attempted to delete all library items', req.user)
// return res.sendStatus(403)
// }
// Logger.info('Removing all Library Items')
// var success = await this.db.recreateLibraryItemsDb()
// if (success) res.sendStatus(200)
// else res.sendStatus(500)
}
// POST: api/items/:id/scan (admin)
async scan(req, res) {
if (!req.user.isAdminOrUp) {

View file

@ -104,7 +104,6 @@ class ApiRouter {
this.router.post('/items/batch/get', LibraryItemController.batchGet.bind(this))
this.router.post('/items/batch/quickmatch', LibraryItemController.batchQuickMatch.bind(this))
this.router.post('/items/batch/scan', LibraryItemController.batchScan.bind(this))
this.router.delete('/items/all', LibraryItemController.deleteAll.bind(this))
this.router.get('/items/:id', LibraryItemController.middleware.bind(this), LibraryItemController.findOne.bind(this))
this.router.patch('/items/:id', LibraryItemController.middleware.bind(this), LibraryItemController.update.bind(this))