node-ipgeoblock
node-ipgeoblock copied to clipboard
Middleware to allow or block requests based on origin country.
I would like to propose support of IP2Location LITE database as another alternative source of IP geolocation. The IP2Location node.js library is available in [ip2location-nodejs](https://github.com/ip2location/ip2location-nodejs) Thank you and keep up...
Line 26: fs.close(geo2); Should be changed to: fs.closeSync(geo2);
I want to allow connections only from my country, but when I allow ["XX"] it will block also my local IP. It really makes it difficult to use my own...
On newer versions of FS, they require async functions to have a callback. Since `fs.close` is an async, it throws an error when you run the code (and crashes everything)....