about summary refs log tree commit homepage
path: root/lib/PublicInbox/Inbox.pm
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2020-05-15 16:11:47 -0500
committerEric Wong <e@yhbt.net>2020-05-15 23:30:12 +0000
commit0a556c99c0db5160f43931422a563c6094b64ea2 (patch)
tree4bf962bcae57bb9858d4d4c60b14c70bc4efeb62 /lib/PublicInbox/Inbox.pm
parent78888d36fb80889f6b0f8ca6f26edda145c14238 (diff)
downloadpublic-inbox-0a556c99c0db5160f43931422a563c6094b64ea2.tar.gz
PublicInbox::Config.pm::_fill() assumes that address is an array.
Therefore when handling an unset address use an array containing a
single string, instead of a single string.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Diffstat (limited to 'lib/PublicInbox/Inbox.pm')
-rw-r--r--lib/PublicInbox/Inbox.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/Inbox.pm b/lib/PublicInbox/Inbox.pm
index 617b692b..002b980f 100644
--- a/lib/PublicInbox/Inbox.pm
+++ b/lib/PublicInbox/Inbox.pm
@@ -102,7 +102,7 @@ sub _set_limiter ($$$) {
 
 sub new {
         my ($class, $opts) = @_;
-        my $v = $opts->{address} ||= 'public-inbox@example.com';
+        my $v = $opts->{address} ||= [ 'public-inbox@example.com' ];
         my $p = $opts->{-primary_address} = ref($v) eq 'ARRAY' ? $v->[0] : $v;
         $opts->{domain} = ($p =~ /\@(\S+)\z/) ? $1 : 'localhost';
         my $pi_config = delete $opts->{-pi_config};