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

Store user away state and add it to the anope.user RPC event.

This commit is contained in:
Sadie Powell
2025-05-09 14:47:31 +01:00
parent 459f3d07c9
commit 977780d8ef
6 changed files with 57 additions and 15 deletions
+11
View File
@@ -508,6 +508,17 @@ public:
root.Reply("account", nullptr);
}
if (u->IsAway())
{
root.ReplyMap("away")
.Reply("message", u->awaymsg)
.Reply("time", u->awaytime);
}
else
{
root.Reply("away", nullptr);
}
auto &channels = root.ReplyArray("channels");
for (const auto &[_, cc] : u->chans)
channels.Reply(cc->status.BuildModePrefixList() + cc->chan->name);