mirror of
https://github.com/anope/anope.git
synced 2026-07-09 09:03:13 +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:
@@ -46,10 +46,9 @@ bool WebCPanel::NickServ::Alist::OnRequest(HTTPProvider *server, const Anope::st
|
||||
|
||||
replacements["NUMBERS"] = stringify(chan_count);
|
||||
replacements["CHANNELS"] = (ci->HasExt("CS_NO_EXPIRE") ? "!" : "") + ci->name;
|
||||
Anope::string access_str;
|
||||
for (unsigned i = 0; i < access.size(); ++i)
|
||||
access_str += ", " + access[i]->AccessSerialize();
|
||||
replacements["ACCESSES"] = access_str.substr(2);
|
||||
|
||||
const ChanAccess *highest = access.Highest();
|
||||
replacements["ACCESSES"] = highest ? highest->AccessSerialize() : "";
|
||||
}
|
||||
|
||||
TemplateFileServer page("nickserv/alist.html");
|
||||
|
||||
Reference in New Issue
Block a user