0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-04 21:08:57 +01:00

ircd:Ⓜ️:homeserver: Fix missing conditions for write-avoid functionality.

This commit is contained in:
Jason Volk 2020-07-27 22:16:04 -07:00
parent 6c2736f592
commit daa3cd6284

View file

@ -260,7 +260,7 @@ try
_vm.reset(nullptr);
}};
if(dbs::events && sequence(*dbs::events) == 0)
if(!ircd::write_avoid && dbs::events && sequence(*dbs::events) == 0)
{
if(opts->bootstrap_vector_path)
bootstrap_event_vector(*this);
@ -268,12 +268,16 @@ try
bootstrap(*this);
}
if(key && !key->verify_keys.empty())
m::keys::cache::set(key->verify_keys);
signon(*this);
mods::imports.emplace("net_dns_cache"s, "net_dns_cache"s);
m::init::backfill::init();
if(!ircd::write_avoid)
{
if(key && !key->verify_keys.empty())
m::keys::cache::set(key->verify_keys);
signon(*this);
m::init::backfill::init();
}
}
catch(const std::exception &e)
{
@ -300,7 +304,7 @@ noexcept try
server::init::wait();
m::sync::pool.join();
if(_vm)
if(!ircd::write_avoid && _vm)
signoff(*this);
///TODO: XXX primary