def create_bot(con) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
      net = con.network
      chan_ary = channel_array(con.core.config, network)
      cc = self
      Cinch::Bot.new do
        configure do |c|
          c.channels      = chan_ary
          c.local_host    = net.bind
          c.modes         = net.modes.to_s.gsub(/\A\+/, '').chars.uniq
          c.nick          = net.nick
          c.password      = net.server_password
          c.port          = net.real_port
          c.realname      = Codebot::WEBSITE
          if net.sasl?
            c.sasl.username = net.sasl_username
            c.sasl.password = net.sasl_password
          end
          c.server        = net.host
          c.ssl.use       = net.secure
          c.ssl.verify    = net.secure
          c.user          = Codebot::PROJECT.downcase
          cc.configure_nickserv_identification(net, c)
        end
        on(:join) { con.set_ready! }
      end
    end
def create_bot(con) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
      net = con.network
      chan_ary = channel_array(con.core.config, network)
      cc = self
      Cinch::Bot.new do
        configure do |c|
          c.channels      = chan_ary
          c.local_host    = net.bind
          c.modes         = net.modes.to_s.gsub(/\A\+/, '').chars.uniq
          c.nick          = net.nick
          c.password      = net.server_password
          c.port          = net.real_port
          c.realname      = Codebot::WEBSITE
          if net.sasl?
            c.sasl.username = net.sasl_username
            c.sasl.password = net.sasl_password
          end
          c.server        = net.host
          c.ssl.use       = net.secure
          c.ssl.verify    = net.secure
          c.user          = Codebot::PROJECT.downcase
          cc.configure_nickserv_identification(net, c)
        end
        on(:join) { con.set_ready! }
      end
    end
Constructs a new bot for the given IRC network.

 @param con [IRCConnection] the connection the thread controls