summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-15 17:26:43 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-15 17:26:43 +0000
commita88e285baa753b5139e539ac3b7919dbdeb54386 (patch)
tree5bca5e253b5b04acc07e40237daef9b6a812dc3a /src
parent2e2f1e98a6123aa1177623f92480ce7ba3c55acb (diff)
Improve notices, so that if SAJOIN fails it can tell the oper who issued it
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5259 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/modules/m_sajoin.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/modules/m_sajoin.cpp b/src/modules/m_sajoin.cpp
index dee6746cd..b305033c9 100644
--- a/src/modules/m_sajoin.cpp
+++ b/src/modules/m_sajoin.cpp
@@ -62,10 +62,22 @@ class cmd_sajoin : public command_t
chanrec* n = ServerInstance->FindChan(parameters[1]);
if (n)
{
- return (n->HasUser(dest) ? CMD_SUCCESS : CMD_FAILURE);
+ if (n->HasUser(dest))
+ {
+ ServerInstance->WriteOpers(std::string(user->nick)+" used SAJOIN to make "+std::string(dest->nick)+" join "+parameters[1]);
+ return CMD_SUCCESS;
+ }
+ else
+ {
+ user->WriteServ("NOTICE "+std::string(user->nick)+" :*** Could not join "+std::string(user->nick)+" to "+parameters[1]+" (User is probably banned, or blocking modes)");
+ return CMD_FAILURE;
+ }
}
else
+ {
+ user->WriteServ("NOTICE "+std::string(user->nick)+" :*** Could not join "+std::string(user->nick)+" to "+parameters[1]);
return CMD_FAILURE;
+ }
}
return CMD_SUCCESS;