mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-17 03:44:20 +03:00
Added [] return rather than 404 for no segments with matching hash
This commit is contained in:
@@ -20,10 +20,10 @@ module.exports = async function (req, res) {
|
||||
|
||||
// Get all video id's that match hash prefix
|
||||
const videoIds = db.prepare('all', 'SELECT DISTINCT videoId, hashedVideoID from sponsorTimes WHERE hashedVideoID LIKE ?', [hashPrefix+'%']);
|
||||
if (videoIds.length === 0) {
|
||||
/*if (videoIds.length === 0) {
|
||||
res.sendStatus(404);
|
||||
return;
|
||||
}
|
||||
}*/
|
||||
|
||||
let segments = videoIds.map((video) => {
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user