From: Eric Wong Date: Sun, 20 Sep 2015 09:33:45 +0000 (+0000) Subject: newsgroup: use only the first address X-Git-Tag: v1.0.0~857 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=2409d31225754eb27f2bea9cc4dc91d73f48fbc8;p=public-inbox.git newsgroup: use only the first address public-inboxen may be aliased to multiple email addresses, and we have always favored the first. --- diff --git a/lib/PublicInbox/NewsGroup.pm b/lib/PublicInbox/NewsGroup.pm index b8aed529..0c7051db 100644 --- a/lib/PublicInbox/NewsGroup.pm +++ b/lib/PublicInbox/NewsGroup.pm @@ -13,6 +13,7 @@ sub new { my ($class, $name, $git_dir, $address) = @_; my $self = fields::new($class); $self->{name} = $name; + $address = $address->[0] if ref($address); $self->{domain} = ($address =~ /\@(\S+)\z/) ? $1 : 'localhost'; $self->{git_dir} = $git_dir; $self->{address} = $address;