Roasted Bean Deploy commited on
Commit
cdcf596
Β·
1 Parent(s): ac212a2

πŸ”§ Fix health endpoint route order

Browse files
Files changed (1) hide show
  1. server.js +3 -3
server.js CHANGED
@@ -181,6 +181,9 @@ app.put('/api/info', requireAuth, (req, res) => {
181
  res.json(data.info);
182
  });
183
 
 
 
 
184
  // ── Serve HTML ──────────────────────────────────────────────────────────────
185
  app.get('/admin', (req, res) => {
186
  res.sendFile(path.join(__dirname, 'public', 'admin.html'));
@@ -192,9 +195,6 @@ app.get('*', (req, res) => {
192
  });
193
 
194
  // ── Start ───────────────────────────────────────────────────────────────────
195
- app.get('/health', (req, res) => res.json({ status: 'ok' }));
196
-
197
  app.listen(PORT, '0.0.0.0', () => {
198
  console.log(`β˜• The Roasted Bean serving on 0.0.0.0:${PORT}`);
199
- console.log(`πŸ”‘ Admin: /admin`);
200
  });
 
181
  res.json(data.info);
182
  });
183
 
184
+ // ── Health ──────────────────────────────────────────────────────────────────
185
+ app.get('/health', (req, res) => res.json({ status: 'ok' }));
186
+
187
  // ── Serve HTML ──────────────────────────────────────────────────────────────
188
  app.get('/admin', (req, res) => {
189
  res.sendFile(path.join(__dirname, 'public', 'admin.html'));
 
195
  });
196
 
197
  // ── Start ───────────────────────────────────────────────────────────────────
 
 
198
  app.listen(PORT, '0.0.0.0', () => {
199
  console.log(`β˜• The Roasted Bean serving on 0.0.0.0:${PORT}`);
 
200
  });