* libs/uci: Added function get_statevalue
authorSteven Barth <steven@midlink.org>
Sun, 6 Jul 2008 10:56:04 +0000 (10:56 +0000)
committerSteven Barth <steven@midlink.org>
Sun, 6 Jul 2008 10:56:04 +0000 (10:56 +0000)
libs/uci/luasrc/model/uci.lua

index 6662943cf57189182312da1b92c2bd875fe5f9e1..e8700efdcc566d3f9915360bbf51b0bbbe7aa1e4 100644 (file)
@@ -67,6 +67,13 @@ function section(config, type, name, values)
        return stat and name
 end
 
+function get_statevalue(...)
+       set_savedir(savedir_state)
+       local result = get(...)
+       set_savedir(savedir_default)
+       return result
+end
+
 function tset(config, section, values)
        local stat = true
        for k, v in pairs(values) do