lib/awesome_bot/links.rb in awesome_bot-1.13.9 vs lib/awesome_bot/links.rb in awesome_bot-1.13.10
- old
+ new
@@ -12,10 +12,10 @@
elsif (x.scan(')').count == 2) && (x.scan('(').count == 1)
x.gsub(/\)\).*/, ')')
elsif (x.scan(')').count > 0)
if (x.include? 'wikipedia')
if (x.scan(')').count == 1) && (x.scan('(').count == 0)
- x.sub(').','').sub(')','')
+ x.gsub(/\).*/, '')
else
x
end
else
x.gsub(/\).*/, '')