From: Arthur Axel "fREW" Schmidt Date: Tue, 2 Feb 2010 18:39:33 +0000 (+0000) Subject: delete +stuff if stuff exists X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=46e125b5cb34030f0d6dc4af27da8c268944b635;p=dbsrgits%2FDBIx-Class-Historic.git delete +stuff if stuff exists --- diff --git a/lib/DBIx/Class/ResultSet.pm b/lib/DBIx/Class/ResultSet.pm index fc75fe7..c7841e8 100644 --- a/lib/DBIx/Class/ResultSet.pm +++ b/lib/DBIx/Class/ResultSet.pm @@ -299,6 +299,10 @@ sub search_rs { $new_attrs->{$key} = $self->_merge_attr($our_attrs->{$key}, $attrs->{$key}); } + if (List::Util::first { exists $new_attrs->{$_} } qw{select as columns}) { + delete $new_attrs->{$_} for (qw{+select +as +columns}); + } + my $cond = (@_ ? ( (@_ == 1 || ref $_[0] eq "HASH")