Skip to content

Commit

Permalink
Add missing start and stop regex & escape slash
Browse files Browse the repository at this point in the history
Signed-off-by: William Desportes <williamdes@wdes.fr>
  • Loading branch information
williamdes committed Aug 30, 2019
1 parent f2abf35 commit c2d9296
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hooks/commits.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@
$files_eol = array();
foreach ($detail['files'] as $file) {
if (preg_match("@\n\+[^\n]*\t@", $file['patch'])) {
if (! preg_match('^libraries/advisory_rules.*\.txt$', $file['filename'])) {
if (! preg_match('/^libraries\/advisory_rules.*\.txt$/', $file['filename'])) {
$files_tab[] = $file['filename'];
}
}
Expand Down

0 comments on commit c2d9296

Please sign in to comment.