added current flat ip

This commit is contained in:
Martin Donnelly 2019-09-06 22:00:16 +01:00
parent ca20fc00d9
commit d8ffebe181

View File

@ -218,7 +218,6 @@ function getUrl (req, res) {
});
}
function getUrlV2(req, res) {
let final;
const firstUrl = req.params.encoded_id;
@ -245,25 +244,17 @@ function getUrlV2(req, res) {
// console.log('Options', options);
logger.info(`V2 >> getting ${theUrl}`);
request({
url : theUrl,
proxy : 'http://us-wa.proxymesh.com:31280',
tunnel : true
'url' : theUrl,
'proxy' : 'http://uk.proxymesh.com:31280',
'tunnel' : true
}, (err, _res, body) => {
if (!err) {
if (!err)
res.send(body);
} else {
else
res.send('');
}
});
}
app.get('/:encoded_id', cache('15 minutes'), getUrlV2);