We'll want to allow some degree of configuration for
various mailing lists.
my ($inbox) = @_;
my $f = $inbox->{filter};
if ($f && $f =~ /::/) {
+ my @args;
+ # basic line splitting, only
+ # Perhaps we can have proper quote splitting one day...
+ ($f, @args) = split(/\s+/, $f) if $f =~ /\s+/;
+
eval "require $f";
if ($@) {
warn $@;
} else {
- return $f->new;
+ # e.g: PublicInbox::Filter::Vger->new(@args)
+ return $f->new(@args);
}
}
undef;