From a85bc774f9c4acbb2dbc1d9ddd02a460c5555391 Mon Sep 17 00:00:00 2001 From: attilamolnar Date: Sun, 16 Jun 2013 21:53:05 +0200 Subject: Always set the topic in Channel::SetTopic(), move access checks into cmd_topic --- src/modules/m_satopic.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/modules/m_satopic.cpp') diff --git a/src/modules/m_satopic.cpp b/src/modules/m_satopic.cpp index c15c9e91b..56098635b 100644 --- a/src/modules/m_satopic.cpp +++ b/src/modules/m_satopic.cpp @@ -40,10 +40,8 @@ class CommandSATopic : public Command if(target) { - std::string newTopic = parameters[1]; - - // 3rd parameter overrides access checks - target->SetTopic(user, newTopic, true); + const std::string& newTopic = parameters[1]; + target->SetTopic(user, newTopic); ServerInstance->SNO->WriteGlobalSno('a', user->nick + " used SATOPIC on " + target->name + ", new topic: " + newTopic); return CMD_SUCCESS; -- cgit v1.3.1-10-gc9f91