X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=data%2Frbot%2Fplugins%2Flastfm.rb;h=09ea380305ae8166dcf1007a88c8731042001768;hb=25dce328a87fcf2af9fa0e1c2da7ed30b7def441;hp=8c562055b1857cc77522eeecaa1cf3fd23226047;hpb=a6738b25dbe4f8eee9223a60622abac5ac6108e5;p=user%2Fhenk%2Fcode%2Fruby%2Frbot.git diff --git a/data/rbot/plugins/lastfm.rb b/data/rbot/plugins/lastfm.rb index 8c562055..09ea3803 100644 --- a/data/rbot/plugins/lastfm.rb +++ b/data/rbot/plugins/lastfm.rb @@ -36,10 +36,10 @@ class ::LastFmEvent end class LastFmPlugin < Plugin - BotConfig.register BotConfigIntegerValue.new('lastfm.max_events', + Config.register Config::IntegerValue.new('lastfm.max_events', :default => 25, :validate => Proc.new{|v| v > 1}, :desc => "Maximum number of events to display.") - BotConfig.register BotConfigIntegerValue.new('lastfm.default_events', + Config.register Config::IntegerValue.new('lastfm.default_events', :default => 3, :validate => Proc.new{|v| v > 1}, :desc => "Default number of events to display.") @@ -146,7 +146,7 @@ class LastFmPlugin < Plugin end wiki = "This artist doesn't have a description yet. You can help by writing it: #{url}/+wiki?action=edit" - if page.match(/
(.*?)<\/div>/m) + if page.match(/
(.*?)<\/div>/m) wiki = $1.ircify_html end