From f31e78fd9d37379f93aa285cf308c7d464ebe8ba Mon Sep 17 00:00:00 2001 From: Felix Stupp Date: Sun, 6 Oct 2019 11:50:46 +0200 Subject: [PATCH] ping: SQL Select missing rows --- routes/ping.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routes/ping.js b/routes/ping.js index 9e9c79d..5ccce0b 100644 --- a/routes/ping.js +++ b/routes/ping.js @@ -30,7 +30,7 @@ router.get("/", testIP, (req, res) => { }); router.get("/:fqdn", (req, res) => { - db.q.select(IP_TYPES).from("addresses").filter("fqdn", req.params.fqdn).first((e, d) => { + db.q.select(IP_TYPES.concat(IP_TYPES.map(e => e + "LastPing"))).from("addresses").filter("fqdn", req.params.fqdn).first((e, d) => { if (e) return res.status(400).send("Error"); if (!d) return res.status(404).send("Unknown FQDN"); res.send([