// require the db reader 
let mmdbreader = require('maxmind-db-reader');
// open database 
/*mmdbreader.open('./geoip/GEOIP2-Country.mmdb',function(err,countries){
    // get geodata 
    countries.getGeoData('180.151.12.115',function(err,geodata){
        // log data :D 
         
    });
});


// open database 
mmdbreader.open('./geoip/GEOIP2-City.mmdb',function(err,geoData){
    // get geodata 
    geoData.getGeoData('180.151.12.115',function(err,geodata){
        // log data :D 
         
    });
});*/

let geoReader = mmdbreader.openSync('./geoip/GEOIP2-City.mmdb');
// get geodata 
let geodata = geoReader.getGeoDataSync('180.151.12.115');
// log data :D 
 
 
 
 
 
 