aboutsummaryrefslogtreecommitdiffstats
path: root/util/startup.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2018-03-25 17:02:00 +0200
committerKim Alvefur <zash@zash.se>2018-03-25 17:02:00 +0200
commit7e64fa124a1f492ae1952fd278c085490d830954 (patch)
tree9cfa37f110a5e1c00ef39cea8f30e72eac847f72 /util/startup.lua
parent54c57625fa96bfd9567e96f229a77df6de594b6e (diff)
downloadprosody-7e64fa124a1f492ae1952fd278c085490d830954.tar.gz
prosody-7e64fa124a1f492ae1952fd278c085490d830954.zip
configmanager: Move firing of the 'config-reloaded' event into util.startup (fixes #1117)
Diffstat (limited to 'util/startup.lua')
-rw-r--r--util/startup.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/util/startup.lua b/util/startup.lua
index a48c2fc7..ba83eca5 100644
--- a/util/startup.lua
+++ b/util/startup.lua
@@ -229,6 +229,11 @@ function startup.add_global_prosody_functions()
elseif level == "file" then
log("error", "Couldn't read the config file when trying to reload: %s", tostring(err));
end
+ else
+ prosody.events.fire_event("config-reloaded", {
+ filename = prosody.config_file,
+ config = config.getconfig(),
+ });
end
return ok, (err and tostring(level)..": "..tostring(err)) or nil;
end