🐋💁 Checkpoint

./server.js:933874/13077
This commit is contained in:
Glitch (hello-express) 2020-03-25 11:51:27 +00:00
parent 5105785b75
commit 38c520b9d5
1 changed files with 15 additions and 6 deletions

View File

@ -59,12 +59,21 @@ app.get("/api", (req, res) => {
"Access-Control-Allow-Headers",
"Origin, X-Requested-With, Content-Type, Accept"
);
res.send({
fuzIsOpen,
lastSeen,
lastClosed,
processUptime: new Date(process.uptime() * 1000).toISOString().substr(11, 8)
});
res.header("Content-Type", "application/json");
res.send(
JSON.stringify(
{
fuzIsOpen,
lastSeen,
lastClosed,
processUptime: new Date(process.uptime() * 1000)
.toISOString()
.substr(11, 8)
},
null,
4
)
);
});
app.get("/status", (req, res) => {