Software /
code /
prosody
Comparison
util/datamanager.lua @ 5250:6d8ec8c90240
util.datamanager: Don't escape the name of a store
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 16 Dec 2012 14:36:24 +0100 |
parent | 5244:775d98184acf |
child | 5440:a943e5cbf083 |
comparison
equal
deleted
inserted
replaced
5248:13553f4132a8 | 5250:6d8ec8c90240 |
---|---|
279 list = "list"; | 279 list = "list"; |
280 } | 280 } |
281 | 281 |
282 function users(host, store, typ) | 282 function users(host, store, typ) |
283 typ = type_map[typ or "keyval"]; | 283 typ = type_map[typ or "keyval"]; |
284 local store_dir = format("%s/%s/%s", data_path, encode(host), encode(store)); | 284 local store_dir = format("%s/%s/%s", data_path, encode(host), store); |
285 | 285 |
286 local mode, err = lfs.attributes(store_dir, "mode"); | 286 local mode, err = lfs.attributes(store_dir, "mode"); |
287 if not mode then | 287 if not mode then |
288 return function() log("debug", err or (store_dir .. " does not exist")) end | 288 return function() log("debug", err or (store_dir .. " does not exist")) end |
289 end | 289 end |