From 379c178f59699321f96b44b19c4d809f667c67cf Mon Sep 17 00:00:00 2001 From: "Navy.gif" Date: Wed, 23 Mar 2022 23:09:17 +0200 Subject: [PATCH] lol woops --- server/src/client/endpoints/Home.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/src/client/endpoints/Home.js b/server/src/client/endpoints/Home.js index 227b7c3..053d4f2 100644 --- a/server/src/client/endpoints/Home.js +++ b/server/src/client/endpoints/Home.js @@ -37,12 +37,12 @@ class Home extends Endpoint { async get(req, res) { console.log('\n\n\nPATH', req.path, '\n\n\n'); - const { path, hostname, protocol } = req; + const { path, protocol } = req; if ((/\/media\/.+/u).test(path)) { const title = decodeURI(path.replace('/media/', '')); const clip = this.client.clipIndex.getByTitle(title); - const baseUrl = `${protocol}://${hostname}`; + const baseUrl = `${protocol}://${this.client.domain}`; const clientUrl = `${baseUrl}${path}`; const thumbnailUrl = `${baseUrl}/thumbnails/${clip.thumbnail}`; const clipUrl = `${baseUrl}/clips/${clip.filename}`;