Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ip-geoinfo

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ip-geoinfo - npm Package Compare versions

Comparing version 1.1.0 to 1.1.1

10

index.js
/*jslint node: true */
'use strict';
const rp = require('request-promise');
const ipGeoInfo = module.exports = function (ipAddress) {
const rp = require('request-promise'),
ipGeoInfo = module.exports = (ipAddress) => {

@@ -15,7 +15,7 @@ if (/^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/.test(ipAddress)) {

return rp(req)
.then(function (res) {
.then( (res) => {
return res;
})
.catch(function (err) {
console.log("Not valid ip");
.catch( (err) => {
console.log("Timeout");
});

@@ -22,0 +22,0 @@ } else {

{
"name": "ip-geoinfo",
"version": "1.1.0",
"version": "1.1.1",
"description": "Get geolocation information about an IP Address",

@@ -10,2 +10,3 @@ "main": "index.js",

"dependencies": {
"ip-regex": "^2.1.0",
"request": "^2.81.0",

@@ -31,3 +32,3 @@ "request-promise": "^4.2.1"

"license": "MIT",
"bugs": {
"bugs": {
"url": "https://github.com/bharathvaj1995/ip-geoinfo/issues"

@@ -34,0 +35,0 @@ },

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc