fix: fix loading custom themes with a custom LEMMY_UI_EXTRA_THEMES_FOLDER

This commit is contained in:
Michał 2023-06-16 18:32:21 +02:00 committed by GitHub
parent 80e2c9602e
commit ad2bf18ab4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -87,7 +87,7 @@ server.get("/css/themes/:name", async (req, res) => {
res.send("Theme must be a css file"); res.send("Theme must be a css file");
} }
const customTheme = path.resolve(`./${extraThemesFolder}/${theme}`); const customTheme = path.resolve(`${extraThemesFolder}/${theme}`);
if (existsSync(customTheme)) { if (existsSync(customTheme)) {
res.sendFile(customTheme); res.sendFile(customTheme);
} else { } else {