From fae4baa30e641de3bc345a8eed21489a2f5ef278 Mon Sep 17 00:00:00 2001 From: Giuseppe Bilotta Date: Tue, 31 Jul 2007 21:10:43 +0000 Subject: Store the real_name information from WHO replies --- lib/rbot/irc.rb | 2 +- lib/rbot/rfc2812.rb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/rbot') diff --git a/lib/rbot/irc.rb b/lib/rbot/irc.rb index efc71c39..59abceec 100644 --- a/lib/rbot/irc.rb +++ b/lib/rbot/irc.rb @@ -885,7 +885,7 @@ module Irc class User < Netmask alias :to_s :nick - attr :real_name + attr_accessor :real_name # Create a new IRC User from a given Netmask (or anything that can be converted # into a Netmask) provided that the given Netmask does not have globs. diff --git a/lib/rbot/rfc2812.rb b/lib/rbot/rfc2812.rb index 98f086e3..2d4d323b 100644 --- a/lib/rbot/rfc2812.rb +++ b/lib/rbot/rfc2812.rb @@ -1130,7 +1130,7 @@ module Irc else warning "Strange WHO reply: #{serverstring.inspect}" end - data[:hopcount], data[:real] = argv[7].split(" ", 2) + data[:hopcount], data[:real_name] = argv[7].split(" ", 2) user = @server.get_user(data[:nick]) @@ -1140,7 +1140,7 @@ module Irc # TODO ircop status # TODO userserver # TODO hopcount - # TODO real + user.real_name = data[:real_name] channel = @server.get_channel(data[:channel]) -- cgit v1.2.3