diff options
| author | 2025-03-02 14:15:02 +0000 | |
|---|---|---|
| committer | 2025-03-03 14:00:16 +0000 | |
| commit | 2102b065d4ed91c5199c1dececdec4e385657cfd (patch) | |
| tree | 344337bb5099dcbf3c0aba113d3ec07955ef00f9 /src/modules/m_hideoper.cpp | |
| parent | Add an 005 token to let clients know that fakelag is enabled. (diff) | |
Add Duration::ToHuman and update messages to use it.
Diffstat (limited to 'src/modules/m_hideoper.cpp')
| -rw-r--r-- | src/modules/m_hideoper.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/m_hideoper.cpp b/src/modules/m_hideoper.cpp index af9500563..786c962fe 100644 --- a/src/modules/m_hideoper.cpp +++ b/src/modules/m_hideoper.cpp @@ -157,7 +157,7 @@ public: std::string extra; if (oper->IsAway()) { - const std::string awayperiod = Duration::ToString(ServerInstance->Time() - oper->away->time); + const std::string awayperiod = Duration::ToHuman(ServerInstance->Time() - oper->away->time); const std::string awaytime = Time::ToString(oper->away->time); extra = INSP_FORMAT(": away for {} [since {}] ({})", awayperiod, awaytime, oper->away->message); @@ -166,7 +166,7 @@ public: auto* loper = IS_LOCAL(oper); if (loper) { - const std::string idleperiod = Duration::ToString(ServerInstance->Time() - loper->idle_lastmsg); + const std::string idleperiod = Duration::ToHuman(ServerInstance->Time() - loper->idle_lastmsg); const std::string idletime = Time::ToString(loper->idle_lastmsg); extra += INSP_FORMAT("{} idle for {} [since {}]", extra.empty() ? ':' : ',', idleperiod, idletime); |
