ip-utilties 1.0.3 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/ip.mjs +1 -5
package/package.json
CHANGED
package/src/ip.mjs
CHANGED
|
@@ -158,11 +158,7 @@ export function isIPv6(address) {
|
|
|
158
158
|
}
|
|
159
159
|
|
|
160
160
|
function _definition(address) {
|
|
161
|
-
|
|
162
|
-
if (_is(defintion, address)) {
|
|
163
|
-
return defintion;
|
|
164
|
-
}
|
|
165
|
-
}
|
|
161
|
+
return [ipv4, ipv6].find(d => _is(d, address));
|
|
166
162
|
}
|
|
167
163
|
|
|
168
164
|
function _is(definition, address) {
|