summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/modes/umode_o.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/modes/umode_o.cpp b/src/modes/umode_o.cpp
index baeaad5bb..71bf10077 100644
--- a/src/modes/umode_o.cpp
+++ b/src/modes/umode_o.cpp
@@ -37,10 +37,9 @@ ModeAction ModeUserOperator::OnModeChange(User* source, User* dest, Channel*, st
* verifying as an oper and getting an opertype assigned
* to your User!
*/
- if (IS_LOCAL(dest))
- ServerInstance->SNO->WriteToSnoMask('o', "User %s de-opered (by %s)", dest->nick.c_str(), source.empty() ? source->server : source->nick.c_str());
- else
- ServerInstance->SNO->WriteToSnoMask('O', "User %s de-opered (by %s)", dest->nick.c_str(), source.empty() ? source->server : source->nick.c_str());
+ char snomask = IS_LOCAL(dest) ? 'o' : 'O';
+ ServerInstance->SNO->WriteToSnoMask(snomask, "User %s de-opered (by %s)", dest->nick.c_str(),
+ source->nick.empty() ? source->server : source->nick.c_str());
dest->UnOper();
return MODEACTION_ALLOW;