cinchrb/cinch — Issue #53: Helper methods not available from plugins?
Author: seventoes
Created: 2011-11-02 02:17:47+00:00
State: open

In my bot:

helpers do
def shutup?
@shutup = false if @shutup_expire <= @shutup
!!@shutup
end
end

And in a plugin:

m.reply @factoids[matches[2].downcase] unless @bot.shutup?

But when running I get:

factoids.rb:31:in `listen': undefined method `shutup?' for # (NoMethodError)

Am I misunderstanding how helpers work or is this a bug? I thought it would define the methods in the context of the bot object?