mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-11-17 14:21:17 +01:00
Update podcast episode update endpoint to sanitize subtitle
This commit is contained in:
1 parent
7c0d9efe91
commit
4bdd76d94c
1 file changed
+6
@@ -412,6 +412,12 @@ class PodcastController {
|
||||
Logger.debug(`[PodcastController] Sanitized description from "${req.body[key]}" to "${sanitizedDescription}"`)
|
||||
req.body[key] = sanitizedDescription
|
||||
}
|
||||
} else if (key === 'subtitle' && req.body[key]) {
|
||||
const sanitizedSubtitle = htmlSanitizer.sanitize(req.body[key])
|
||||
if (sanitizedSubtitle !== req.body[key]) {
|
||||
Logger.debug(`[PodcastController] Sanitized subtitle from "${req.body[key]}" to "${sanitizedSubtitle}"`)
|
||||
req.body[key] = sanitizedSubtitle
|
||||
}
|
||||
}
|
||||
|
||||
updatePayload[key] = req.body[key]
|
||||
|
||||
Reference in new issue
Block a user