luci-base: add uci.get_bool to allow cleanup of app code
Any number of apps read boolean values from configuration files, then use
various inconsistent means for checking truth values. The get_bool function
allows app authors to fetch the value without regard for how it is represented
in the config file.
For example, this
let enabled = uci.get('system', 'ntp', 'enable_server');
if (enabled == '1') ...
could become the more natural
let enabled = uci.get_bool('system', 'ntp', 'enable_server');
if (enabled) ...
Signed-off-by: Eric Fahlgren <[email protected]>