From bffd263617d01764b6a04d1f29771ddaab20f352 Mon Sep 17 00:00:00 2001 From: David Bauer Date: Mon, 15 Aug 2022 00:37:32 +0200 Subject: [PATCH] gluon-core: return boolean from preserve_channels This method previously returned the string literal of the config key, leading to checks evaluating to true even in case this option was disabled. Signed-off-by: David Bauer --- package/gluon-core/luasrc/usr/lib/lua/gluon/wireless.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/gluon-core/luasrc/usr/lib/lua/gluon/wireless.lua b/package/gluon-core/luasrc/usr/lib/lua/gluon/wireless.lua index 62fe3228..ea6343b9 100644 --- a/package/gluon-core/luasrc/usr/lib/lua/gluon/wireless.lua +++ b/package/gluon-core/luasrc/usr/lib/lua/gluon/wireless.lua @@ -123,7 +123,7 @@ function M.foreach_radio(uci, f) end function M.preserve_channels(uci) - return uci:get('gluon', 'wireless', 'preserve_channels') + return uci:get_bool('gluon', 'wireless', 'preserve_channels') end function M.device_supports_wpa3()