1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 05:27:43 +00:00

LibCore+LibConfig+ConfigServer: Add Config::{add,remove}_group()

Plumbs synchronous calls for adding and removing group entries to
config files. This is useful for services like SystemServer which
default to group names for executable paths, and for removing all
keys at once.
This commit is contained in:
thankyouverycool 2022-09-23 09:45:05 -04:00 committed by Ali Mohammad Pur
parent 6f394d9ee2
commit c34f2e75e9
10 changed files with 97 additions and 0 deletions

View file

@ -234,6 +234,12 @@ bool ConfigFile::has_group(String const& group) const
return m_groups.contains(group);
}
void ConfigFile::add_group(String const& group)
{
m_groups.ensure(group);
m_dirty = true;
}
void ConfigFile::remove_group(String const& group)
{
m_groups.remove(group);