resultset is defined would make a SQL COUNT happen.
use strict;
use warnings;
+
=head1 NAME
DBIx::Class::CDBICompat::Iterator
use base qw(DBIx::Class::ResultSet);
sub _bool {
- return $_[0]->count;
+ # Performance hack so internal checks whether the result set
+ # exists won't do a SQL COUNT.
+ return 1 if caller =~ /^DBIx::Class::/;
+
+ return $_[0]->count;
}
1;