lib/ruboty/adapters/slack_rtm.rb in ruboty-slack_rtm-3.2.4 vs lib/ruboty/adapters/slack_rtm.rb in ruboty-slack_rtm-3.2.5
- old
+ new
@@ -244,9 +244,10 @@
[CGI.unescapeHTML(text), mention_to]
end
def resolve_send_mention(text)
+ return '' if text.nil?
text = text.dup.to_s
text.gsub!(/@(?<mention>[0-9a-z._-]+)/) do |_|
mention = Regexp.last_match[:mention]
msg = "@#{mention}"