Update:API endpoints for library and library item scan updated to POST requests

This commit is contained in:
advplyr 2023-02-03 17:50:42 -06:00
parent c93f17051a
commit b957e1a36b
6 changed files with 9 additions and 9 deletions

View file

@ -684,13 +684,13 @@ class LibraryController {
res.sendStatus(200)
}
// GET: api/libraries/:id/scan
// POST: api/libraries/:id/scan
async scan(req, res) {
if (!req.user.isAdminOrUp) {
Logger.error(`[LibraryController] Non-root user attempted to scan library`, req.user)
return res.sendStatus(403)
}
var options = {
const options = {
forceRescan: req.query.force == 1
}
res.sendStatus(200)