Commit b6314019 authored by Olivier Salaün's avatar Olivier Salaün
Browse files

Sympa::Scenario::new() was unable to load scenario filename including dots....

Sympa::Scenario::new() was unable to load scenario filename including dots. Example: visibility.igr.univ-rennes1.fr
parent 7164bc79
......@@ -151,10 +151,10 @@ sub new {
unless (
defined $name
and ( $function eq 'include' and $name =~ m{\A[^/]+\z}
or $name =~ /\A[-\w]+\z/)
or $name =~ /\A[-\w\.]+\z/)
) {
$log->syslog('err', 'Unknown or undefined scenario function "%s"',
$function);
$log->syslog('err', 'Unknown or undefined scenario function "%s", scenario name "%s"',
$function, $name);
return undef;
}
......@@ -1617,6 +1617,8 @@ sub get_scenarios {
my $scenario =
Sympa::Scenario->new($that, $function, name => $name);
$seen{$name} = 1;
next unless (defined $scenario);
push @scenarios, $scenario;
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment