From 8f4b013b639c64bdf7ab2f07c66801240ed6bcb5 Mon Sep 17 00:00:00 2001 From: Sebastian Hildebrandt Date: Tue, 19 Mar 2024 08:17:26 +0100 Subject: [PATCH] networkInterfaces() fixed speed of not connected interfaces (windows) --- CHANGELOG.md | 3 ++- docs/history.html | 5 +++++ docs/index.html | 2 +- lib/network.js | 2 +- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index efa6cb31..9e552ff2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -83,7 +83,8 @@ For major (breaking) changes - **version 4, 3 and 2** - see end of page. | Version | Date | Comment | | ------- | ---------- | --------------------------------------------------------------------------------------------------- | -| 5.22.5 | 2024-03-19 | `wifiCOnnections()` fixed formatting bssid (macOS) | +| 5.22.6 | 2024-03-20 | `networkInterfaces()` fixed speed of not connected interfaces (windows) | +| 5.22.5 | 2024-03-19 | `wifiConnections()` fixed formatting bssid (macOS) | | 5.22.4 | 2024-03-16 | `uuid()` improved parsing machine id (linux) | | 5.22.3 | 2024-03-15 | `chassis()` improved parsing memory bank (windows) | | 5.22.2 | 2024-03-14 | `chassis()` type, assetTag, sku improved parsing (macOS) | diff --git a/docs/history.html b/docs/history.html index e5efcf1e..1ace3147 100644 --- a/docs/history.html +++ b/docs/history.html @@ -57,6 +57,11 @@

Full version history

+ + 5.22.6 + 2024-03-20 + networkInterfaces() fixed speed of not connected interfaces (windows) + 5.22.5 2024-03-19 diff --git a/docs/index.html b/docs/index.html index b2e98849..c1cc93d2 100644 --- a/docs/index.html +++ b/docs/index.html @@ -170,7 +170,7 @@
systeminformation
 
-
New Version: 5.22.5
+
New Version: 5.22.6
diff --git a/lib/network.js b/lib/network.js index 4c2ebb2e..c779fe37 100644 --- a/lib/network.js +++ b/lib/network.js @@ -1033,7 +1033,7 @@ function networkInterfaces(callback, rescan, defaultString) { ifaceName = detail.name; dhcp = detail.dhcp; operstate = detail.operstate; - speed = detail.speed; + speed = operstate === 'up' ? detail.speed : 0; type = detail.type; foundFirst = true; }