Comparison

util/startup.lua @ 10389:dbb8dae58265 0.11

util.startup: Update config path (fixes #1430)
author Kim Alvefur <zash@zash.se>
date Sun, 03 Nov 2019 22:19:09 +0100
parent 9762:34988a408b74
child 10390:82705ec87253
comparison
equal deleted inserted replaced
10385:62a7042e0771 10389:dbb8dae58265
31 filename = _filename; 31 filename = _filename;
32 local file = io.open(filename); 32 local file = io.open(filename);
33 if file then 33 if file then
34 file:close(); 34 file:close();
35 prosody.config_file = filename; 35 prosody.config_file = filename;
36 CFG_CONFIGDIR = filename:match("^(.*)[\\/][^\\/]*$"); -- luacheck: ignore 111 36 prosody.paths.config = filename:match("^(.*)[\\/][^\\/]*$");
37 CFG_CONFIGDIR = prosody.paths.config; -- luacheck: ignore 111
37 break; 38 break;
38 end 39 end
39 end 40 end
40 prosody.config_file = filename 41 prosody.config_file = filename
41 local ok, level, err = config.load(filename); 42 local ok, level, err = config.load(filename);