X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=lib%2FPublicInbox%2FConfig.pm;h=d57c361ad90cd8364629201021b485c7b715cb46;hb=d94b6dd63438174888db27f3a61ffdcf7d1a99da;hp=8ccf337dc0071c4c409567be4a43a239c357984d;hpb=8fdea96141a65ac85d22d21ed9e3f999259ee73c;p=public-inbox.git diff --git a/lib/PublicInbox/Config.pm b/lib/PublicInbox/Config.pm index 8ccf337d..d57c361a 100644 --- a/lib/PublicInbox/Config.pm +++ b/lib/PublicInbox/Config.pm @@ -364,13 +364,23 @@ sub _fill { my ($self, $pfx) = @_; my $ibx = {}; - foreach my $k (qw(inboxdir filter newsgroup - watch httpbackendmax - replyto feedmax nntpserver - indexlevel indexsequentialshard)) { + for my $k (qw(watch nntpserver)) { my $v = $self->{"$pfx.$k"}; $ibx->{$k} = $v if defined $v; } + for my $k (qw(filter inboxdir newsgroup replyto httpbackendmax feedmax + indexlevel indexsequentialshard)) { + if (defined(my $v = $self->{"$pfx.$k"})) { + if (ref($v) eq 'ARRAY') { + warn <[-1]' +EOF + $ibx->{$k} = $v->[-1]; + } else { + $ibx->{$k} = $v; + } + } + } # backwards compatibility: $ibx->{inboxdir} //= $self->{"$pfx.mainrepo"}; @@ -414,8 +424,9 @@ sub _fill { $self->{-no_obfuscate}->{$lc_addr} = 1; } if (my $listids = $ibx->{listid}) { + # RFC2919 section 6 stipulates "case insensitive equality" foreach my $list_id (@$listids) { - $self->{-by_list_id}->{$list_id} = $ibx; + $self->{-by_list_id}->{lc($list_id)} = $ibx; } } if (my $ng = $ibx->{newsgroup}) {