Skip to content

Commit

Permalink
Merge pull request #1745 from ikedas/issue-1742
Browse files Browse the repository at this point in the history
Missing validation on Digest frequency in Edit Config (#1742)
  • Loading branch information
racke authored Dec 1, 2023
2 parents 06d14c0 + 3c37ca0 commit 944b721
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/lib/Sympa/Config.pm
Original file line number Diff line number Diff line change
Expand Up @@ -815,7 +815,7 @@ sub _validate_changes_leaf {
{p_info => $pitem, p_paths => $ppaths, value => $new}
];
return 'invalid';
} elsif (ref $format ne 'ARRAY' and not $new =~ /^$format$/) {
} elsif (ref $format ne 'ARRAY' and not $new =~ /\A(?:$format)\z/) {
push @$errors,
[
'user', 'syntax_errors',
Expand Down
4 changes: 2 additions & 2 deletions src/lib/Sympa/Config/Schema.pm
Original file line number Diff line number Diff line change
Expand Up @@ -888,15 +888,15 @@ our %pinfo = (
context => [qw(list)],
order => 2,
gettext_id => "hour",
format => '\d+',
format => '[01]?[0-9]|2[0-3]',
occurrence => '1',
length => 2
},
minute => {
context => [qw(list)],
order => 3,
gettext_id => "minute",
format => '\d+',
format => '[0-5]?[0-9]',
occurrence => '1',
length => 2
}
Expand Down

0 comments on commit 944b721

Please sign in to comment.