From 26742bbd83970b0e2b54e4fca83b93a3a94c36f8 Mon Sep 17 00:00:00 2001 From: Tim Wilkinson Date: Sun, 4 Jun 2023 17:24:28 -0700 Subject: [PATCH] Fix 'has_wifi' detection. (#863) /sys/kernel/debug/ieee80211 can exist without entries sometimes --- files/usr/lib/lua/aredn/hardware.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/usr/lib/lua/aredn/hardware.lua b/files/usr/lib/lua/aredn/hardware.lua index d2d614a3..08f34289 100644 --- a/files/usr/lib/lua/aredn/hardware.lua +++ b/files/usr/lib/lua/aredn/hardware.lua @@ -260,7 +260,7 @@ function hardware.has_usb() end function hardware.has_wifi() - if nixio.fs.stat("/sys/kernel/debug/ieee80211") then + if nixio.fs.stat("/sys/kernel/debug/ieee80211/phy0") then return true else return false