From 2409d31225754eb27f2bea9cc4dc91d73f48fbc8 Mon Sep 17 00:00:00 2001
From: Eric Wong <e@80x24.org>
Date: Sun, 20 Sep 2015 09:33:45 +0000
Subject: [PATCH] newsgroup: use only the first address

public-inboxen may be aliased to multiple email addresses,
and we have always favored the first.
---
 lib/PublicInbox/NewsGroup.pm | 1 +
 1 file changed, 1 insertion(+)

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;
-- 
2.50.0