aboutsummaryrefslogtreecommitdiffstats
path: root/uci.py
diff options
context:
space:
mode:
Diffstat (limited to 'uci.py')
-rw-r--r--uci.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/uci.py b/uci.py
index 883c17f..ab9397a 100644
--- a/uci.py
+++ b/uci.py
@@ -134,7 +134,13 @@ def main():
## Get key and value - I need to make decisions
key, skey = get_uci_key(package, section, type, index, name)
- val = uci_get(module, bin_path, key)
+ if key:
+ val = uci_get(module, bin_path, key)
+ else:
+ val = None
+
+ if not val:
+ sval = uci_get(module, bin_path, skey)
## Handle deletes
if state == "absent":