From 5b061f31cf2a7ebe0f0a80fdd53ffb2e3fd9982d Mon Sep 17 00:00:00 2001 From: w00t Date: Mon, 13 Oct 2008 11:50:42 +0000 Subject: Don't send an override notice if no modes were actually applied, thanks Ankit. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10640 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_override.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/modules/m_override.cpp b/src/modules/m_override.cpp index 56e7dae7c..8c3ea1bda 100644 --- a/src/modules/m_override.cpp +++ b/src/modules/m_override.cpp @@ -66,6 +66,8 @@ class ModuleOverride : public Module if ((OverriddenMode) && (irc::string(command.c_str()) == "MODE") && (result == CMD_SUCCESS)) { int Total = OverOps + OverDeops + OverVoices + OverDevoices + OverHalfops + OverDehalfops; + if (Total == 0) + return; ServerInstance->SNO->WriteToSnoMask('O',std::string(user->nick)+" Overriding modes: "+ServerInstance->Modes->GetLastParse()+" "+(Total ? "[Detail: " : "")+ (OverOps ? ConvToStr(OverOps)+" op"+(OverOps != 1 ? "s" : "")+" " : "")+ -- cgit v1.2.3