Sha256: 5f52f18cec317f7bf40698e48b1c38eeeabbc77c60b81e765fc0f545bfda0cc1

Contents?: true

Size: 460 Bytes

Versions: 33

Compression:

Stored size: 460 Bytes

Contents

module Admin
  class Autojoin
    include Cinch::Plugin
    include Cinch::Helpers

    # Listeners
    listen_to :invite, method: :join_and_notify

    enable_acl(:nobody)


    # Methods
    def join_and_notify(m)
      if Config.options.key? :join_on_invite
        log2chan("#{m.user.nick} has requested me join #{m.channel}", :notice)
        Channel(m.channel).join
      end
    end

  end
end

# AutoLoad
Bot.config.plugins.plugins.push Admin::Autojoin

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
zetabot-2.1.2 lib/Zeta/admin/autojoin.rb
zetabot-2.1.1 lib/Zeta/admin/autojoin.rb
zetabot-2.1.0 lib/Zeta/admin/autojoin.rb
zetabot-2.0.9 lib/Zeta/admin/autojoin.rb
zetabot-2.0.8 lib/Zeta/admin/autojoin.rb
zetabot-2.0.7 lib/Zeta/admin/autojoin.rb
zetabot-2.0.6 lib/Zeta/admin/autojoin.rb
zetabot-2.0.5 lib/Zeta/admin/autojoin.rb
zetabot-2.0.4 lib/Zeta/admin/autojoin.rb
zetabot-2.0.3 lib/Zeta/admin/autojoin.rb
zetabot-2.0.2 lib/Zeta/admin/autojoin.rb
zetabot-2.0.1 lib/Zeta/admin/autojoin.rb
zetabot-2.0.0 lib/Zeta/admin/autojoin.rb
zetabot-1.1.0 lib/Zeta/admin/autojoin.rb
zetabot-1.0.7 lib/Zeta/admin/autojoin.rb
zetabot-1.0.6 lib/Zeta/admin/autojoin.rb
zetabot-1.0.5 lib/Zeta/admin/autojoin.rb
zetabot-1.0.4 lib/Zeta/admin/autojoin.rb
zetabot-1.0.3 lib/Zeta/admin/autojoin.rb
zetabot-1.0.2 lib/Zeta/admin/autojoin.rb