From e32d7fd4c1f3fdc298453d3182d5eec49736f1f3 Mon Sep 17 00:00:00 2001 From: tomsmeding Date: Mon, 26 Dec 2016 17:01:09 +0100 Subject: Explicitly serve hostname --- serverstore.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/serverstore.js b/serverstore.js index 21876ee..1d04530 100755 --- a/serverstore.js +++ b/serverstore.js @@ -8,7 +8,7 @@ var fs=require("fs"), Persist=require("node-persist"), glob=require("glob"); -var HTTPPORT=42420; +var HOSTNAME="tomsmeding.com",HTTPPORT=42420; Persist.initSync({}); @@ -97,7 +97,7 @@ app.post("/ss/image/:userid/:authhash/:fname",function(req,res){ fs.mkdirSync("images/"+req.ssuser[0]); } fs.writeFileSync("images/"+req.ssuser[0]+"/"+req.ssfname,req.body); - res.end("http://"+req.hostname+"/ss/get/"+req.ssuser[0]+"/"+req.sscode); + res.end("https://"+HOSTNAME+"/ss/get/"+req.ssuser[0]+"/"+req.sscode); }); -- cgit v1.2.3-70-g09d2