aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules/m_cban.cpp
diff options
context:
space:
mode:
authorGravatar Sadie Powell2019-03-30 22:06:19 +0000
committerGravatar Sadie Powell2019-03-30 22:06:19 +0000
commit1fff2f7f87fa0e69494fe45902cfa315204d1e43 (patch)
treeb4f3eac01dc458cc7f3ab5b43a57c44d06044bed /src/modules/m_cban.cpp
parentRemove the flashpolicyd module. (diff)
parentRename OnClientProtocolPopulateTags to OnPopulateTags. (diff)
downloadinspircd++-1fff2f7f87fa0e69494fe45902cfa315204d1e43.tar.gz
inspircd++-1fff2f7f87fa0e69494fe45902cfa315204d1e43.tar.bz2
inspircd++-1fff2f7f87fa0e69494fe45902cfa315204d1e43.zip
Merge branch 'insp3' into master.
Diffstat (limited to 'src/modules/m_cban.cpp')
-rw-r--r--src/modules/m_cban.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/modules/m_cban.cpp b/src/modules/m_cban.cpp
index a9f0e50eb..316b6dc2c 100644
--- a/src/modules/m_cban.cpp
+++ b/src/modules/m_cban.cpp
@@ -88,7 +88,7 @@ class CommandCBan : public Command
public:
CommandCBan(Module* Creator) : Command(Creator, "CBAN", 1, 3)
{
- flags_needed = 'o'; this->syntax = "<channel> [<duration> :<reason>]";
+ flags_needed = 'o'; this->syntax = "<channel> [<duration> [:<reason>]]";
}
CmdResult Handle(User* user, const Params& parameters) override
@@ -130,9 +130,9 @@ class CommandCBan : public Command
}
else
{
- time_t c_requires_crap = duration + ServerInstance->Time();
- std::string timestr = InspIRCd::TimeString(c_requires_crap);
- ServerInstance->SNO.WriteGlobalSno('x', "%s added timed CBan for %s, expires on %s: %s", user->nick.c_str(), parameters[0].c_str(), timestr.c_str(), reason);
+ ServerInstance->SNO.WriteGlobalSno('x', "%s added timed CBan for %s, expires in %s (on %s): %s",
+ user->nick.c_str(), parameters[0].c_str(), InspIRCd::DurationString(duration).c_str(),
+ InspIRCd::TimeString(ServerInstance->Time() + duration).c_str(), reason);
}
}
else