0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-29 18:22:50 +01:00

modules/s_conf: Update conf items from !conf state values on startup.

This commit is contained in:
Jason Volk 2018-03-06 11:57:57 -08:00
parent daa1d6481c
commit 90528245de

View file

@ -47,6 +47,11 @@ noexcept
unquote(content.at("value"))
};
log::debug
{
"Updating conf [%s] => %s", key, value
};
ircd::conf::set(key, value);
}
@ -64,7 +69,16 @@ update_conf_hook
static void
init_conf_items(const m::event &)
{
const m::room::state state
{
conf_room
};
state.for_each("ircd.conf.item", []
(const m::event &event)
{
update_conf(event);
});
}
const m::hook