mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-09 21:17:15 +03:00
removed status from no segment responses
This commit is contained in:
@@ -17,7 +17,6 @@ module.exports = (req, res) => {
|
|||||||
|| categories.length === 0
|
|| categories.length === 0
|
||||||
) {
|
) {
|
||||||
res.status(400).json({
|
res.status(400).json({
|
||||||
status: 400,
|
|
||||||
message: 'Bad Format'
|
message: 'Bad Format'
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
@@ -29,7 +28,6 @@ module.exports = (req, res) => {
|
|||||||
|
|
||||||
if (!userIsVIP) {
|
if (!userIsVIP) {
|
||||||
res.status(403).json({
|
res.status(403).json({
|
||||||
status: 403,
|
|
||||||
message: 'Must be a VIP to mark videos.'
|
message: 'Must be a VIP to mark videos.'
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
@@ -65,14 +63,12 @@ module.exports = (req, res) => {
|
|||||||
logger.error("Error submitting 'noSegment' marker for category '" + category + "' for video '" + videoID + "'");
|
logger.error("Error submitting 'noSegment' marker for category '" + category + "' for video '" + videoID + "'");
|
||||||
logger.error(err);
|
logger.error(err);
|
||||||
res.status(500).json({
|
res.status(500).json({
|
||||||
status: 500,
|
|
||||||
message: "Internal Server Error: Could not write marker to the database."
|
message: "Internal Server Error: Could not write marker to the database."
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
res.status(200).json({
|
res.status(200).json({
|
||||||
status: 200,
|
|
||||||
submitted: categoriesToMark
|
submitted: categoriesToMark
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
@@ -40,7 +40,6 @@ describe('noSegmentRecords', () => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
let expected = {
|
let expected = {
|
||||||
status: 200,
|
|
||||||
submitted: [
|
submitted: [
|
||||||
'outro',
|
'outro',
|
||||||
'shilling'
|
'shilling'
|
||||||
|
|||||||
Reference in New Issue
Block a user