ActivityPub-federated video streaming platform using P2P directly in your web browser
Fix server build
Chocobozzz67c604ae691e
diff --git a/server/middlewares/validators/oembed.ts b/server/middlewares/validators/oembed.tsindex 24ba5569dc..ab4dbb4d18 100644--- a/server/middlewares/validators/oembed.ts+++ b/server/middlewares/validators/oembed.ts@@ -37,8 +37,11 @@ const oembedValidator = [.end()}- const startIsOk = req.query.url.startsWith(urlShouldStartWith)- const matches = videoWatchRegex.exec(req.query.url)+ const url = req.query.url as string++ const startIsOk = url.startsWith(urlShouldStartWith)+ const matches = videoWatchRegex.exec(url)+if (startIsOk === false || matches === null) {return res.status(400).json({ error: 'Invalid url.' })