1
0
mirror of https://github.com/anope/anope.git synced 2026-06-30 09:36: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
+1 -7
View File
@@ -25,13 +25,7 @@ using namespace Message;
void Away::Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags)
{
const Anope::string &msg = !params.empty() ? params[0] : "";
FOREACH_MOD(OnUserAway, (source.GetUser(), msg));
if (!msg.empty())
Log(source.GetUser(), "away") << "is now away: " << msg;
else
Log(source.GetUser(), "away") << "is no longer away";
source.GetUser()->SetAway(params.empty() ? "" : params[0]);
}
void Capab::Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags)