diff options
author | BuildTools <unconfigured@null.spigotmc.org> | 2017-09-27 09:48:24 +0200 |
---|---|---|
committer | BuildTools <unconfigured@null.spigotmc.org> | 2017-09-27 09:48:24 +0200 |
commit | 69b48673b901082c0b71df5a796b6f5af2e9c63e (patch) | |
tree | e60b5885d735e31842c9784562f91e7159e39012 | |
parent | js bug (diff) |
app.js
-rw-r--r-- | app.js | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -7,7 +7,7 @@ const fs = require('fs'); const converter = new showdown.Converter(); const app = express(); -const path = 'md' +const path = 'md'; app.use(express.static('public')); @@ -41,7 +41,11 @@ app.get('/', function(req, res) { }); }); -var server = app.listen(8080, function() { +app.get('*', function(req, res) { + res.status(404).send('Are you a teapot ?'); +}); + +var server = app.listen(80, function() { var host = server.address().address; var port = server.address().port; console.log("App listening at http://%s:%s", host, port); |