Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v8.0.0 always returns *.*.*.0 instead of actual IP #48

Open
Tracked by #1344
lohfu opened this issue Jun 20, 2023 · 3 comments · May be fixed by #49
Open
Tracked by #1344

v8.0.0 always returns *.*.*.0 instead of actual IP #48

lohfu opened this issue Jun 20, 2023 · 3 comments · May be fixed by #49

Comments

@lohfu
Copy link

lohfu commented Jun 20, 2023

It seems calling normalize on

return normalize(cidr).split('/')[0];
converts eg 10.13.37.100/24 to 10.13.37.0/24. Thus, the actual IP of the computer will never be returned.

@sindresorhus
Copy link
Owner

// @silverwind

@iBicha
Copy link

iBicha commented Jun 23, 2023

Same, happens on mac
7.0.0 => http://192.168.1.182
8.0.0 => http://192.168.1.0

@adipascu
Copy link

adipascu commented Mar 4, 2024

v8.0.0 of this library has some regressions and points to the incorrect IP, I am sticking with v7 as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants