ActivityPub-federated video streaming platform using P2P directly in your web browser
Add correct status on not found video
Chocobozzzc08579e14fe7
diff --git a/server/lib/client-html.ts b/server/lib/client-html.tsindex 2fcf0c4eae..e595056144 100644--- a/server/lib/client-html.ts+++ b/server/lib/client-html.ts@@ -37,6 +37,7 @@ export class ClientHtml {static async getWatchHTMLPage (videoId: string, req: express.Request, res: express.Response) {// Let Angular application handle errorsif (!validator.isInt(videoId) && !validator.isUUID(videoId, 4)) {+ res.status(404)return ClientHtml.getIndexHTML(req, res)}@@ -47,7 +48,8 @@ export class ClientHtml {// Let Angular application handle errorsif (!video || video.privacy === VideoPrivacy.PRIVATE || video.privacy === VideoPrivacy.INTERNAL || video.VideoBlacklist) {- return ClientHtml.getIndexHTML(req, res)+ res.status(404)+ return html}let customHtml = ClientHtml.addTitleTag(html, escapeHTML(video.name))@@ -77,6 +79,7 @@ export class ClientHtml {// Let Angular application handle errorsif (!entity) {+ res.status(404)return ClientHtml.getIndexHTML(req, res)}