]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 1251047 - fix to work with right function
authorDylan William Hardison <dylan@hardison.net>
Mon, 29 Feb 2016 18:35:50 +0000 (13:35 -0500)
committerDylan William Hardison <dylan@hardison.net>
Mon, 29 Feb 2016 18:35:50 +0000 (13:35 -0500)
Bugzilla/User.pm

index 04b3d32ad35d70922436d77883435bff24f2f8bf..89c5574e3ffad976a7344c2d1ae60cd40917ab94 100644 (file)
@@ -55,7 +55,7 @@ use Bugzilla::BugUserLastVisit;
 
 use DateTime::TimeZone;
 use List::Util qw(max);
-use List::MoreUtils qw(any bsearch);
+use List::MoreUtils qw(any);
 use Scalar::Util qw(blessed);
 use Storable qw(dclone);
 use URI;
@@ -1302,7 +1302,7 @@ sub clear_product_cache {
 sub can_see_product {
     my ($self, $product_name) = @_;
 
-    return bsearch { $_->name cmp $product_name } @{$self->get_selectable_products};
+    return any { $_->name cmp $product_name } @{$self->get_selectable_products};
 }
 
 sub get_selectable_products {