diff options
| author | 2025-03-03 14:58:58 +0000 | |
|---|---|---|
| committer | 2025-03-03 14:58:58 +0000 | |
| commit | d4d2293244c1845d2ca44708e82cad0bd38741e5 (patch) | |
| tree | e6c03e062dd5b2dc13f215169ab11455a2b89d88 /src/usermanager.cpp | |
| parent | Merge branch 'insp4' into master. (diff) | |
| parent | Use Duration::ToHuman instead of seconds in various messages. (diff) | |
Merge branch 'insp4' into master.
Diffstat (limited to 'src/usermanager.cpp')
| -rw-r--r-- | src/usermanager.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/usermanager.cpp b/src/usermanager.cpp index 67edb608c..8cdf2d63f 100644 --- a/src/usermanager.cpp +++ b/src/usermanager.cpp @@ -27,6 +27,7 @@ #include "inspircd.h" #include "clientprotocolmsg.h" #include "iohook.h" +#include "timeutils.h" #include "xline.h" namespace @@ -65,7 +66,7 @@ namespace if (!user->lastping) { time_t secs = ServerInstance->Time() - (user->nextping - user->GetClass()->pingtime); - const std::string message = FMT::format("Ping timeout: {} {}", secs, (secs != 1 ? "seconds" : "second")); + const std::string message = FMT::format("Ping timeout: {}", Duration::ToHuman(secs)); ServerInstance->Users.QuitUser(user, message); return; } |
