Software /
code /
prosody
Comparison
util/datamanager.lua @ 4108:e3e3aa286334
util.datamanager: Handle gracefully the lack of prosody.paths.data
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Tue, 11 Jan 2011 04:19:03 +0000 |
parent | 4093:36555949bd16 |
child | 4112:09f0ba0cfbfc |
comparison
equal
deleted
inserted
replaced
4106:e19fc274e182 | 4108:e3e3aa286334 |
---|---|
55 _mkdir[path] = true; | 55 _mkdir[path] = true; |
56 end | 56 end |
57 return path; | 57 return path; |
58 end | 58 end |
59 | 59 |
60 local data_path = prosody.paths.data; | 60 local data_path = (prosody and prosody.paths and prosody.paths.data) or "."; |
61 local callbacks = {}; | 61 local callbacks = {}; |
62 | 62 |
63 ------- API ------------- | 63 ------- API ------------- |
64 | 64 |
65 function set_data_path(path) | 65 function set_data_path(path) |