1
0
mirror of https://github.com/anope/anope.git synced 2026-06-28 21:36:37 +02:00

Rewrite access path system to be simplier and use recursion

Show where access is "from" in chanserv/status
This commit is contained in:
Adam
2016-02-13 14:16:29 -05:00
parent addd2a1987
commit 4e2ca31cf5
9 changed files with 165 additions and 113 deletions
+7 -2
View File
@@ -236,9 +236,14 @@ class CommandSeen : public Command
AccessGroup ag = source.c->ci->AccessFor(na->nc);
time_t last = 0;
for (unsigned i = 0; i < ag.size(); ++i)
for (unsigned int i = 0; i < ag.paths.size(); ++i)
{
ChanAccess *a = ag[i];
ChanAccess::Path &p = ag.paths[i];
if (p.empty())
continue;
ChanAccess *a = p[p.size() - 1];
if (a->GetAccount() == na->nc && a->last_seen > last)
last = a->last_seen;