From 01876f7f818771b076c221be9d94f2d74edc7150 Mon Sep 17 00:00:00 2001 From: Gregg Tavares Date: Fri, 12 Feb 2016 20:20:11 +0800 Subject: [PATCH] add fakeHFTSitePing to shut up hftsite code --- server/hft-server.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/server/hft-server.js b/server/hft-server.js index 395fb23d..3e4d3c4e 100644 --- a/server/hft-server.js +++ b/server/hft-server.js @@ -707,10 +707,20 @@ var HFTServer = function(options, startedCallback) { }); }; + // if we're in DNS mode we'll get messages from games trying to + // inform happyfuntimes.net + function fakeHFTSitePing(req, res) { + res.json({ + ip: "0.0.0.0", + }); + } + app.get(/^\/games\/(.*?)\//, sendGameRequestedFile); app.get(/^\/enter-name.html/, sendTemplatedFile); app.use(/^\/api\/v0\/install\//, busboy()); app.post(/^\/api\/v0\/install\//, installUploadedFile); + app.use(/^\/api\/inform2/, busboy()); + app.post(/^\/api\/inform2/, fakeHFTSitePing); app.use(/^\/api\/v0\/uploadFile\//, busboy()); app.post(/^\/api\/v0\/uploadFile\//, addUploadedFile); app.get(/.*/, sendSystemRequestedFile);