Fix http vs https

This commit is contained in:
Jake
2014-11-29 14:17:40 -06:00
parent fd7fbc0f3c
commit a40a3819d8
2 changed files with 3 additions and 3 deletions

View File

@@ -6,7 +6,7 @@ var router = express.Router();
router.get('/', function(req, res) {
res.render('index', {
title: 'Crafatar',
domain: "https://" + req.headers.host,
domain: req.secure ? "https" : "http" + "://" + req.headers.host,
config: config
});
});