Skip to content
Snippets Groups Projects
Commit 05cc75ea authored by Ghazi Triki's avatar Ghazi Triki
Browse files

Validate kind in putRecordingTextTrack.

parent 6667360c
No related branches found
No related tags found
No related merge requests found
......@@ -119,6 +119,12 @@ class RecordingController {
if (StringUtils.isEmpty(params.kind)) {
respondWithError("paramError", "Missing param kind.")
return
} else {
def isAllowedKind = StringUtils.strip(params.kind) in ['subtitles', 'captions']
if (!isAllowedKind) {
respondWithError("invalidKind", "The kind parameter is not set to a permitted value.")
return
}
}
String captionsKind = StringUtils.strip(params.kind)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment