0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-02 02:02:43 +00:00

Add proper error popup when theme fails to load

This commit is contained in:
Trevor Buckner
2024-07-28 16:45:01 -04:00
parent edec9369ec
commit 8aa88a2e45
7 changed files with 56 additions and 23 deletions

View File

@@ -9,7 +9,7 @@ const yaml = require('js-yaml');
const app = express();
const config = require('./config.js');
const { homebrewApi, getBrew, getThemeBundle, getUsersBrewThemes } = require('./homebrew.api.js');
const { homebrewApi, getBrew, getUsersBrewThemes } = require('./homebrew.api.js');
const GoogleActions = require('./googleActions.js');
const serveCompressedStaticAssets = require('./static-assets.mv.js');
const sanitizeFilename = require('sanitize-filename');
@@ -77,9 +77,6 @@ app.get('/robots.txt', (req, res)=>{
return res.sendFile(`robots.txt`, { root: process.cwd() });
});
// Theme
app.get('/theme/:renderer/:id', asyncHandler(getThemeBundle));
//Home page
app.get('/', (req, res, next)=>{
req.brew = {