A lot of updates
This commit is contained in:
@@ -161,6 +161,14 @@ InstanceHandler::InstanceHandler(SqlDataManager *sql) : sql(sql) {
|
||||
|
||||
this->properties()[property::SERVERINSTANCE_UNIQUE_ID] = ""; /* we def got a new instance */
|
||||
}
|
||||
if(this->default_tree->channel_count() == 4) {
|
||||
auto default_channel = this->default_tree->findChannel("[cspacer04]Default Channel", nullptr);
|
||||
if(default_channel) {
|
||||
auto ch = this->default_tree->createChannel(0, default_channel->channelId(), "[cspacer05]Administrator Room");
|
||||
ch->permissions()->set_permission(permission::i_channel_needed_view_power, {75, 0}, permission::v2::set_value, permission::v2::do_nothing, false, false);
|
||||
this->save_channel_permissions();
|
||||
}
|
||||
}
|
||||
if(!this->default_tree->getDefaultChannel()) this->default_tree->setDefaultChannel(this->default_tree->findChannel("[cspacer04]Default Channel", nullptr));
|
||||
if(!this->default_tree->getDefaultChannel()) this->default_tree->setDefaultChannel(*this->default_tree->channels().begin());
|
||||
assert(this->default_tree->getDefaultChannel());
|
||||
|
||||
Reference in New Issue
Block a user