In the newest version of cinch it appears that setting a plugin-specific prefix no longer works the same way. Copying your example code in https://github.com/cinchrb/cinch/blob/master/examples/plugins/custom_prefix.rb verbatim and running it produces the error:
bot.rb:7:in <class:SomeCommand>': wrong number of arguments (1 for 0) (ArgumentError)
<class:SomeCommand>': wrong number of arguments (1 for 0) (ArgumentError)
I have Cinch 2.0.3 and Ruby 1.9.2p290 installed. Is there something I'm missing, or can you provide some new example code for setting a plugin-specific prefix? Thanks!
It has to be self.prefix = ... or set :prefix, ... instead. I'll fix the example when I get to it.
self.prefix = ...
set :prefix, ...
Fixing incorrect prefix syntax
The prefix should be set through 'set'.
Fixes issue #98 on the original repo.
fix examples that broke with Cinch 2.0
Fix plugin examples to use new "set" syntax for options