mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-11 05:57:04 +03:00
Check that start time is not less than zero
This commit is contained in:
@@ -148,7 +148,7 @@ module.exports = async function postSkipSegments(req, res) {
|
||||
let endTime = parseFloat(segments[i].segment[1]);
|
||||
|
||||
if (isNaN(startTime) || isNaN(endTime)
|
||||
|| startTime === Infinity || endTime === Infinity || startTime > endTime) {
|
||||
|| startTime === Infinity || endTime === Infinity || startTime < 0 || startTime > endTime) {
|
||||
//invalid request
|
||||
res.sendStatus(400);
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user