From ecbf4dad7149174c8065193a9a33ec6f4561ac2a Mon Sep 17 00:00:00 2001 From: stickler-ci Date: Fri, 19 Aug 2022 21:44:23 +0000 Subject: [PATCH] Fixing style errors. --- pkg/ircslack/channel.go | 2 +- pkg/ircslack/irc_context.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/ircslack/channel.go b/pkg/ircslack/channel.go index adf53dc..95fed22 100644 --- a/pkg/ircslack/channel.go +++ b/pkg/ircslack/channel.go @@ -101,7 +101,7 @@ func (c *Channel) IsPublicChannel() bool { // IsPrivateChannel returns true if the channel is private. func (c *Channel) IsPrivateChannel() bool { - return (c.IsGroup||c.IsChannel) && c.IsPrivate + return (c.IsGroup || c.IsChannel) && c.IsPrivate } // IsMP returns true if it is a multi-party conversation. diff --git a/pkg/ircslack/irc_context.go b/pkg/ircslack/irc_context.go index 90cbeab..10a0a09 100644 --- a/pkg/ircslack/irc_context.go +++ b/pkg/ircslack/irc_context.go @@ -99,9 +99,9 @@ func (ic *IrcContext) Start() { if message.TargetTs != "" { opts = append(opts, slack.MsgOptionTS(message.TargetTs)) if target[1] == ChannelPrefixThread[0] { - idx := strings.Index(target,message.TargetTs) + idx := strings.Index(target, message.TargetTs) // strip the prefixes and the '-timestamp' - target = target[2:idx-1] + target = target[2 : idx-1] } } if _, _, err := ic.SlackClient.PostMessage(target, opts...); err != nil {