summaryrefslogtreecommitdiffstats
path: root/aconf/persistence/backends/augeas.lua
diff options
context:
space:
mode:
Diffstat (limited to 'aconf/persistence/backends/augeas.lua')
-rw-r--r--aconf/persistence/backends/augeas.lua12
1 files changed, 6 insertions, 6 deletions
diff --git a/aconf/persistence/backends/augeas.lua b/aconf/persistence/backends/augeas.lua
index 46d3ea9..7ce68f0 100644
--- a/aconf/persistence/backends/augeas.lua
+++ b/aconf/persistence/backends/augeas.lua
@@ -5,7 +5,7 @@ See LICENSE file for license details
local topology = require('aconf.model.root').topology
local class = require('aconf.object').class
-local address = require('aconf.path.address')
+local pth = require('aconf.path')
local tostr = require('aconf.persistence.util').tostring
local util = require('aconf.util')
@@ -92,7 +92,7 @@ local function conv_path(path)
keys = {}
end
- top = top and top(address.escape(comp))
+ top = top and top(pth.escape(comp))
mode = top and top.mode
table.remove(path, 1)
@@ -194,7 +194,7 @@ function backend:set(mods)
local ppath, pmode = conv_path(parent)
if is_selector(pmode) then
- gc[address.join('/', table.unpack(parent))] = false
+ gc[pth.join('/', table.unpack(parent))] = false
if pmode == 'enumerate' then
local count = #self.aug:match(ppath)
@@ -259,11 +259,11 @@ function backend:set(mods)
self.aug:set(apath, value ~= nil and tostr(value) or nil)
end
- util.setdefault(gc, address.join('/', table.unpack(path)), true)
+ util.setdefault(gc, pth.join('/', table.unpack(path)), true)
end
for path, _ in pairs(gc) do
- local p = address.split(path)
+ local p = pth.split(path)
while #p > 0 do
local value = self:get(p)
@@ -275,7 +275,7 @@ function backend:set(mods)
break
end
- if gc[address.join('/', table.unpack(p))] ~= false then
+ if gc[pth.join('/', table.unpack(p))] ~= false then
self.aug:rm(conv_path(p))
end
p[#p] = nil