From 755a32c75101c4df0e5699db558785fc0dbc1973 Mon Sep 17 00:00:00 2001 From: Matt Schatz Date: Sun, 17 Feb 2019 02:23:32 -0700 Subject: Start using DurationString() in X-line additions and a few other modules where it fits better than just showing seconds. --- src/modules/m_shun.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/modules/m_shun.cpp') diff --git a/src/modules/m_shun.cpp b/src/modules/m_shun.cpp index e54156da6..b4e538624 100644 --- a/src/modules/m_shun.cpp +++ b/src/modules/m_shun.cpp @@ -110,15 +110,14 @@ class CommandShun : public Command { if (!duration) { - ServerInstance->SNO->WriteToSnoMask('x',"%s added permanent SHUN for %s: %s", + ServerInstance->SNO->WriteToSnoMask('x', "%s added permanent SHUN for %s: %s", user->nick.c_str(), target.c_str(), expr.c_str()); } else { - time_t c_requires_crap = duration + ServerInstance->Time(); - std::string timestr = InspIRCd::TimeString(c_requires_crap); - ServerInstance->SNO->WriteToSnoMask('x', "%s added timed SHUN for %s to expire on %s: %s", - user->nick.c_str(), target.c_str(), timestr.c_str(), expr.c_str()); + ServerInstance->SNO->WriteToSnoMask('x', "%s added timed SHUN for %s to expire in %s (on %s): %s", + user->nick.c_str(), target.c_str(), InspIRCd::DurationString(duration).c_str(), + InspIRCd::TimeString(ServerInstance->Time() + duration).c_str(), expr.c_str()); } } else -- cgit v1.3.1-10-gc9f91