mirror of
https://github.com/ergochat/ergo.git
synced 2025-12-20 10:10:08 -08:00
get rid of extra topic messages
This commit is contained in:
parent
488b2ccf8f
commit
ae02596214
1 changed files with 8 additions and 10 deletions
|
|
@ -242,20 +242,18 @@ func (m *TopicCommand) HandleChannel(channel *Channel) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if m.setTopic {
|
if !m.setTopic {
|
||||||
|
channel.GetTopic(client)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
if channel.flags[OpOnlyTopic] {
|
if channel.flags[OpOnlyTopic] {
|
||||||
client.Reply(ErrChanOPrivIsNeeded(channel))
|
client.Reply(ErrChanOPrivIsNeeded(channel))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
channel.topic = m.topic
|
channel.topic = m.topic
|
||||||
channel.GetTopic(client)
|
|
||||||
channel.Reply(RplTopicMsg(client, channel))
|
channel.Reply(RplTopicMsg(client, channel))
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
channel.GetTopic(client)
|
|
||||||
return
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (m *PrivMsgCommand) HandleChannel(channel *Channel) {
|
func (m *PrivMsgCommand) HandleChannel(channel *Channel) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue