332 end |
332 end |
333 |
333 |
334 function init_data_store() |
334 function init_data_store() |
335 local data_path = config.get("*", "core", "data_path") or CFG_DATADIR or "data"; |
335 local data_path = config.get("*", "core", "data_path") or CFG_DATADIR or "data"; |
336 require "util.datamanager".set_data_path(data_path); |
336 require "util.datamanager".set_data_path(data_path); |
337 require "util.datamanager".add_callback(function(username, host, datastore, data) |
|
338 if config.get(host, "core", "anonymous_login") then |
|
339 return false; |
|
340 end |
|
341 return username, host, datastore, data; |
|
342 end); |
|
343 require "core.storagemanager"; |
337 require "core.storagemanager"; |
344 end |
338 end |
345 |
339 |
346 function prepare_to_start() |
340 function prepare_to_start() |
347 log("info", "Prosody is using the %s backend for connection handling", server.get_backend()); |
341 log("info", "Prosody is using the %s backend for connection handling", server.get_backend()); |