fix: restore inspector template hot reload

This commit is contained in:
Your Name 2026-08-06 16:37:42 -04:00
parent cbbb87cd2e
commit ffba038b35
7 changed files with 232 additions and 35 deletions

View file

@ -1,8 +1,7 @@
function handler(req, res) {
const sql = require("db")("bliss").sql;
const sourceRoute = sql
.prepare("SELECT * FROM routes WHERE id = ?")
.get(req.params.id);
if (!sourceRoute) return res.status(404).send("Route not found");
res.render("inspector/route_editor", { sourceRoute });
const kind = "route";
const artifact = sql.prepare("SELECT * FROM routes WHERE id = ?").get(req.params.id);
if (!artifact) return res.status(404).send("Route not found");
res.render("inspector/artifact_editor", { kind, artifact });
}