From de38fcf7bfbb5b8ba70e54621cb69f0b3aeba65c Mon Sep 17 00:00:00 2001 From: kaotisk Date: Fri, 13 Dec 2024 15:46:45 +0200 Subject: At least reply something --- api/routes/getMap/index.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'api/routes/getMap/index.js') diff --git a/api/routes/getMap/index.js b/api/routes/getMap/index.js index 60c7e0d..791afb5 100644 --- a/api/routes/getMap/index.js +++ b/api/routes/getMap/index.js @@ -21,6 +21,11 @@ module.exports = (req, res) => { res.writeHead(200, {'Content-Type': 'application/json'}); res.end(fs.readFileSync(path)); } + else + { + res.writeHead(404, {'Content-Type': 'application/json'}); + res.end(JSON.stringify({"error":"not found"})); + } } catch (error) { -- cgit v1.2.3