mirror of
https://github.com/Raghu-Ch/ReactWeather.git
synced 2026-02-10 03:03:01 -05:00
updated server.js
This commit is contained in:
@@ -5,7 +5,7 @@ var app = express();
|
|||||||
const PORT = process.env.PORT || 3000;
|
const PORT = process.env.PORT || 3000;
|
||||||
|
|
||||||
app.use(function (req, res, next) {
|
app.use(function (req, res, next) {
|
||||||
if (req.headers['x-forwarded-proto'] === 'http') {
|
if (req.headers['x-forwarded-proto'] === 'https') {
|
||||||
res.redirect('http://' + req.hostname + req.url);
|
res.redirect('http://' + req.hostname + req.url);
|
||||||
} else {
|
} else {
|
||||||
next();
|
next();
|
||||||
|
|||||||
Reference in New Issue
Block a user