0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-09-28 19:58:53 +02:00

modules/s_conf: Handle exception on the update hook.

This commit is contained in:
Jason Volk 2018-04-21 22:54:37 -07:00
parent bd3e004d70
commit 795f0488e4

View file

@ -57,7 +57,7 @@ get_conf_item(const string_view &key,
static void
update_conf(const m::event &event)
noexcept
noexcept try
{
const auto &content
{
@ -81,6 +81,15 @@ noexcept
ircd::conf::set(key, value);
}
catch(const std::exception &e)
{
log::error
{
"Failed to set conf item '%s' :%s",
json::get<"state_key"_>(event),
e.what()
};
}
const m::hook
update_conf_hook