do the split thing.

master
Robert Gerus 2014-03-13 16:37:43 +01:00
parent 487d433a5c
commit 795947c01d
1 changed files with 3 additions and 1 deletions

View File

@ -33,7 +33,8 @@ end
DataMapper.auto_upgrade!
Client.register_trigger("PRIVMSG") do |msg|
msg[:params].each do |word|
return 0 if msg[:params][1].nil?
msg[:params][1].split.each do |word|
if word =~ /^https?:\/\// then
original_url = word
if word =~ /4cdn[.]org/ then
@ -52,6 +53,7 @@ Client.register_trigger("PRIVMSG") do |msg|
)
Client.privmsg(msg[:params][0], Config[:scrape][:title_prefix] + title) if not title.nil?
return 0
end
end
end