mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-10-29 18:00:23 +00:00
Making changes for cloudflare
This commit is contained in:
4
server/node_modules/cors-anywhere/lib/cors-anywhere.js
generated
vendored
4
server/node_modules/cors-anywhere/lib/cors-anywhere.js
generated
vendored
@@ -226,9 +226,9 @@ var getHandler = exports.getHandler = function(options, proxy) {
|
||||
};
|
||||
|
||||
return function(req, res) {
|
||||
if(req.headers.referer && req.headers.referer.substring(0,15) !== "https://zoff.no")
|
||||
if(req.headers.referer && req.headers.referer.substring(0,15) !== "http://zoff.no")
|
||||
{
|
||||
res.writeHead(401, "You're accessing the cors-anywhere from wrong domain, only https://zoff.no is allowed");
|
||||
res.writeHead(401, "You're accessing the cors-anywhere from wrong domain, only http://zoff.no is allowed");
|
||||
res.end();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -26,7 +26,6 @@ var server;
|
||||
cors_proxy.createServer({
|
||||
requireHeader: ['origin', 'x-requested-with'],
|
||||
removeHeaders: ['cookie', 'cookie2'],
|
||||
//httpsOptions: credentials
|
||||
}).listen(8080, function() {
|
||||
console.log('Running CORS Anywhere on :' + 8080);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user