Migration Cleanup
This commit is contained in:
parent
d2c014e744
commit
84225a66f9
8 changed files with 224 additions and 354 deletions
|
|
@ -76,7 +76,9 @@ async function handleStatsPage(req, res) {
|
|||
const url = new URL(`${req.protocol}://${req.get('host')}${req.originalUrl}`);
|
||||
if (url.pathname !== statsUIPath) return false;
|
||||
try {
|
||||
const html = await fs.readFile(path.join(__dirname, 'stats.html'), 'utf8');
|
||||
// Load the stats UI from pages/stats/stats.html in the project root
|
||||
const statsHtmlPath = path.join(rootDir, 'pages', 'stats', 'stats.html');
|
||||
const html = await fs.readFile(statsHtmlPath, 'utf8');
|
||||
res.status(200).type('html').send(html);
|
||||
return true;
|
||||
} catch (e) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue