netforkInterfaces() node 18 compatibility
This commit is contained in:
parent
66b8620243
commit
1a930c9682
@ -80,7 +80,8 @@ For major (breaking) changes - **version 4, 3 and 2** - see end of page.
|
|||||||
|
|
||||||
| Version | Date | Comment |
|
| Version | Date | Comment |
|
||||||
| -------------- | -------------- | -------- |
|
| -------------- | -------------- | -------- |
|
||||||
| 5.11.13 | 2022-04-21 | `etworkStats()` improved scanning (mac OS) |
|
| 5.11.14 | 2022-04-22 | `netforkInterfaces()` node 18 compatibility |
|
||||||
|
| 5.11.13 | 2022-04-21 | `networkStats()` improved scanning (mac OS) |
|
||||||
| 5.11.12 | 2022-04-19 | `battery()` improved M1 support (mac OS) |
|
| 5.11.12 | 2022-04-19 | `battery()` improved M1 support (mac OS) |
|
||||||
| 5.11.11 | 2022-04-19 | `networkInterfaces()` improved parsing (windows) |
|
| 5.11.11 | 2022-04-19 | `networkInterfaces()` improved parsing (windows) |
|
||||||
| 5.11.10 | 2022-04-18 | updated docs |
|
| 5.11.10 | 2022-04-18 | updated docs |
|
||||||
|
|||||||
@ -57,6 +57,11 @@
|
|||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<th scope="row">5.11.14</th>
|
||||||
|
<td>2022-04-22</td>
|
||||||
|
<td><span class="code">networkInterfaces()</span> node 18 compatibility</td>
|
||||||
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th scope="row">5.11.13</th>
|
<th scope="row">5.11.13</th>
|
||||||
<td>2022-04-21</td>
|
<td>2022-04-21</td>
|
||||||
|
|||||||
@ -170,7 +170,7 @@
|
|||||||
<img class="logo" src="assets/logo.png">
|
<img class="logo" src="assets/logo.png">
|
||||||
<div class="title">systeminformation</div>
|
<div class="title">systeminformation</div>
|
||||||
<div class="subtitle"><span id="typed"></span> </div>
|
<div class="subtitle"><span id="typed"></span> </div>
|
||||||
<div class="version">New Version: <span id="version">5.11.13</span></div>
|
<div class="version">New Version: <span id="version">5.11.14</span></div>
|
||||||
<button class="btn btn-light" onclick="location.href='https://github.com/sebhildebrandt/systeminformation'">View on Github <i class=" fab fa-github"></i></button>
|
<button class="btn btn-light" onclick="location.href='https://github.com/sebhildebrandt/systeminformation'">View on Github <i class=" fab fa-github"></i></button>
|
||||||
</div>
|
</div>
|
||||||
<div class="down">
|
<div class="down">
|
||||||
|
|||||||
@ -743,10 +743,10 @@ function networkInterfaces(callback, rescan, defaultString) {
|
|||||||
|
|
||||||
if ({}.hasOwnProperty.call(ifaces, nic.iface)) {
|
if ({}.hasOwnProperty.call(ifaces, nic.iface)) {
|
||||||
ifaces[nic.iface].forEach(function (details) {
|
ifaces[nic.iface].forEach(function (details) {
|
||||||
if (details.family === 'IPv4') {
|
if (details.family === 'IPv4' || details.family === 4) {
|
||||||
nic.ip4subnet = details.netmask;
|
nic.ip4subnet = details.netmask;
|
||||||
}
|
}
|
||||||
if (details.family === 'IPv6') {
|
if (details.family === 'IPv6' || details.family === 6) {
|
||||||
nic.ip6subnet = details.netmask;
|
nic.ip6subnet = details.netmask;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -818,11 +818,11 @@ function networkInterfaces(callback, rescan, defaultString) {
|
|||||||
if ({}.hasOwnProperty.call(ifaces, dev)) {
|
if ({}.hasOwnProperty.call(ifaces, dev)) {
|
||||||
let ifaceName = dev;
|
let ifaceName = dev;
|
||||||
ifaces[dev].forEach(function (details) {
|
ifaces[dev].forEach(function (details) {
|
||||||
if (details.family === 'IPv4') {
|
if (details.family === 'IPv4' || details.family === 4) {
|
||||||
ip4 = details.address;
|
ip4 = details.address;
|
||||||
ip4subnet = details.netmask;
|
ip4subnet = details.netmask;
|
||||||
}
|
}
|
||||||
if (details.family === 'IPv6') {
|
if (details.family === 'IPv6' || details.family === 6) {
|
||||||
if (!ip6 || ip6.match(/^fe80::/i)) {
|
if (!ip6 || ip6.match(/^fe80::/i)) {
|
||||||
ip6 = details.address;
|
ip6 = details.address;
|
||||||
ip6subnet = details.netmask;
|
ip6subnet = details.netmask;
|
||||||
@ -984,11 +984,11 @@ function networkInterfaces(callback, rescan, defaultString) {
|
|||||||
if ({}.hasOwnProperty.call(ifaces, dev)) {
|
if ({}.hasOwnProperty.call(ifaces, dev)) {
|
||||||
let ifaceName = dev;
|
let ifaceName = dev;
|
||||||
ifaces[dev].forEach(function (details) {
|
ifaces[dev].forEach(function (details) {
|
||||||
if (details.family === 'IPv4') {
|
if (details.family === 'IPv4' || details.family === 4) {
|
||||||
ip4 = details.address;
|
ip4 = details.address;
|
||||||
ip4subnet = details.netmask;
|
ip4subnet = details.netmask;
|
||||||
}
|
}
|
||||||
if (details.family === 'IPv6') {
|
if (details.family === 'IPv6' || details.family === 6) {
|
||||||
if (!ip6 || ip6.match(/^fe80::/i)) {
|
if (!ip6 || ip6.match(/^fe80::/i)) {
|
||||||
ip6 = details.address;
|
ip6 = details.address;
|
||||||
ip6subnet = details.netmask;
|
ip6subnet = details.netmask;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user