]> Sergey Matveev's repositories - public-inbox.git/commitdiff
config: allow "0" as a valid mainrepo path
authorEric Wong <e@80x24.org>
Tue, 15 Oct 2019 01:38:25 +0000 (01:38 +0000)
committerEric Wong <e@80x24.org>
Tue, 15 Oct 2019 20:26:41 +0000 (20:26 +0000)
It's probably wrong to use relative path names, but things are
all relative these days anyways with shared and networked FSes.

lib/PublicInbox/Config.pm

index e0329ebf34b945928888879471c8ace7efe26808..509de0a0b844784f6d8c05bbc5d1ac741dd4902b 100644 (file)
@@ -93,7 +93,7 @@ sub each_inbox {
        # may auto-vivify if config file is non-existent:
        foreach my $section (@{$self->{-section_order}}) {
                next if $section !~ m!\Apublicinbox\.([^/]+)\z!;
-               $self->{"publicinbox.$1.mainrepo"} or next;
+               defined($self->{"publicinbox.$1.mainrepo"}) or next;
                my $ibx = lookup_name($self, $1) or next;
                $cb->($ibx);
        }