summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/rbot/message.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/rbot/message.rb b/lib/rbot/message.rb
index 42042b88..c539843b 100644
--- a/lib/rbot/message.rb
+++ b/lib/rbot/message.rb
@@ -150,13 +150,13 @@ module Irc
# Access the nick of the source
#
def sourcenick
- @source.nick
+ @source.nick rescue @source.to_s
end
# Access the user@host of the source
#
def sourceaddress
- "#{@source.user}@#{@source.host}"
+ "#{@source.user}@#{@source.host}" rescue @source.to_s
end
# Was the message from an identified user?