mirror of
https://github.com/anope/anope.git
synced 2026-07-07 04:03:12 +02:00
Add Block::GetBlocks which returns an iterable list of blocks.
This commit is contained in:
@@ -661,10 +661,8 @@ public:
|
||||
{
|
||||
defaultFlags.clear();
|
||||
|
||||
for (int i = 0; i < conf.CountBlock("privilege"); ++i)
|
||||
for (const auto &[_, priv] : conf.GetBlocks("privilege"))
|
||||
{
|
||||
const auto &priv = conf.GetBlock("privilege", i);
|
||||
|
||||
const Anope::string &pname = priv.Get<const Anope::string>("name");
|
||||
|
||||
Privilege *p = PrivilegeManager::FindPrivilege(pname);
|
||||
|
||||
Reference in New Issue
Block a user