Skip to content

Commit

Permalink
fix: regexp normalization on inventory protocol should be case insens…
Browse files Browse the repository at this point in the history
…itive
  • Loading branch information
g-bougard committed Oct 18, 2023
1 parent 16d1430 commit d8e701b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/GLPI/Agent/Protocol/Inventory.pm
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ sub _norm {
# pattern normalization is special as $value should be an array ref in that case
if ($norm eq "pattern" && ref($value) eq 'ARRAY') {
my ($key, $pattern) = @{$value};
return if !defined($entry->{$key}) || $entry->{$key} =~ /$pattern/;
return if !defined($entry->{$key}) || $entry->{$key} =~ /$pattern/i;
$self->{logger}->debug("inventory format: Removing $entrykey $key value as not matching /$pattern/ regexp: '$entry->{$key}'")
if $self->{logger};
delete $entry->{$key};
Expand Down

0 comments on commit d8e701b

Please sign in to comment.