iso-3166-1
Advanced tools
Comparing version 1.0.1 to 1.1.0
{ | ||
"name": "iso-3166-1", | ||
"version": "1.0.1", | ||
"version": "1.1.0", | ||
"description": "Lookup information with ISO 3166-1 alpha-2, ISO 3166-1 alpha-3 and ISO 3166-1 numeric", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -6,5 +6,5 @@ const iso = require('./iso-3166.js'); | ||
return iso.filter(function (country) { | ||
return iso.find(function (country) { | ||
return country.country.toUpperCase() === name; | ||
})[0]; | ||
}); | ||
} | ||
@@ -15,5 +15,5 @@ | ||
return iso.filter(function (country) { | ||
return iso.find(function (country) { | ||
return country.alpha2 === alpha2; | ||
})[0]; | ||
}); | ||
} | ||
@@ -24,5 +24,5 @@ | ||
return iso.filter(function (country) { | ||
return iso.find(function (country) { | ||
return country.alpha3 === alpha3; | ||
})[0]; | ||
}); | ||
} | ||
@@ -33,5 +33,5 @@ | ||
return iso.filter(function (country) { | ||
return iso.find(function (country) { | ||
return country.numeric === numeric; | ||
})[0]; | ||
} | ||
}); | ||
} |
Sorry, the diff of this file is not supported yet
1580
30476