diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2003-01-07 13:22:28 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2003-01-07 13:22:28 +0000 |
commit | c2f200920f04dba0874c054038770a91a71fbba5 (patch) | |
tree | 7448485cea94afcd511535b592b1f061c543f3b9 /perl-install/Xconfig/monitor.pm | |
parent | 0a813b0ea3c7c30ca81e79b6303f5141e95fee4b (diff) | |
download | drakx-backup-do-not-use-c2f200920f04dba0874c054038770a91a71fbba5.tar drakx-backup-do-not-use-c2f200920f04dba0874c054038770a91a71fbba5.tar.gz drakx-backup-do-not-use-c2f200920f04dba0874c054038770a91a71fbba5.tar.bz2 drakx-backup-do-not-use-c2f200920f04dba0874c054038770a91a71fbba5.tar.xz drakx-backup-do-not-use-c2f200920f04dba0874c054038770a91a71fbba5.zip |
use "if any" instead of "if grep", and various other occurences of "any", "every", "partition"
Diffstat (limited to 'perl-install/Xconfig/monitor.pm')
-rw-r--r-- | perl-install/Xconfig/monitor.pm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/Xconfig/monitor.pm b/perl-install/Xconfig/monitor.pm index 3d9415dff..8ca3ba935 100644 --- a/perl-install/Xconfig/monitor.pm +++ b/perl-install/Xconfig/monitor.pm @@ -133,7 +133,7 @@ sub configure_automatic { if ($monitor->{EISA_ID}) { log::l("EISA_ID: $monitor->{EISA_ID}"); - if (my ($mon) = grep { lc($_->{EISA_ID}) eq $monitor->{EISA_ID} } @$monitors) { + if (my $mon = find { lc($_->{EISA_ID}) eq $monitor->{EISA_ID} } @$monitors) { add2hash($monitor, $mon); log::l("EISA_ID corresponds to: $monitor->{ModelName}"); } elsif (!$monitor->{HorizSync} || !$monitor->{VertRefresh}) { @@ -141,7 +141,7 @@ sub configure_automatic { delete @$monitor{'VendorName', 'ModelName', 'EISA_ID'}; } } else { - if (my ($mon) = grep { $_->{VendorName} eq $monitor->{VendorName} && $_->{ModelName} eq $monitor->{ModelName} } @$monitors) { + if (my $mon = find { $_->{VendorName} eq $monitor->{VendorName} && $_->{ModelName} eq $monitor->{ModelName} } @$monitors) { put_in_hash($monitor, $mon); } } |