Software /
code /
prosody
Comparison
util/startup.lua @ 9762:34988a408b74 0.11
util.startup: Always reload logging after config (fixes #1284)
This chancged in 6e24a69b03af likely because of confusion about the
`reopen-log-files` event which was fired but never hooked.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 06 Jan 2019 12:14:42 +0100 |
parent | 9214:8b2b8f1a911f |
child | 9873:dfaeea570f7e |
child | 10389:dbb8dae58265 |
comparison
equal
deleted
inserted
replaced
9742:18eca6afb367 | 9762:34988a408b74 |
---|---|
85 | 85 |
86 function startup.init_logging() | 86 function startup.init_logging() |
87 -- Initialize logging | 87 -- Initialize logging |
88 local loggingmanager = require "core.loggingmanager" | 88 local loggingmanager = require "core.loggingmanager" |
89 loggingmanager.reload_logging(); | 89 loggingmanager.reload_logging(); |
90 prosody.events.add_handler("config-reloaded", function () | |
91 prosody.events.fire_event("reopen-log-files"); | |
92 end); | |
90 prosody.events.add_handler("reopen-log-files", function () | 93 prosody.events.add_handler("reopen-log-files", function () |
91 loggingmanager.reload_logging(); | 94 loggingmanager.reload_logging(); |
92 prosody.events.fire_event("logging-reloaded"); | 95 prosody.events.fire_event("logging-reloaded"); |
93 end); | 96 end); |
94 end | 97 end |