X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FDBIx%2FClass%2FResultSource.pm;h=ce048b93d12865b09662d5f752c9b2b98f20092d;hb=111364b30f1418813dec58ac6aca4492476bd23b;hp=7d172bd33f999131293dce34c6676f71a7110fd5;hpb=c0f4450974f8e44893f6ed3eb107ef4c4bd783fc;p=dbsrgits%2FDBIx-Class.git diff --git a/lib/DBIx/Class/ResultSource.pm b/lib/DBIx/Class/ResultSource.pm index 7d172bd..ce048b9 100644 --- a/lib/DBIx/Class/ResultSource.pm +++ b/lib/DBIx/Class/ResultSource.pm @@ -2116,8 +2116,8 @@ sub _resolve_relationship_condition { next if $col_eqs->{$lhs} eq UNRESOLVABLE_CONDITION; my ($rhs) = @{ is_literal_value( $ret->{condition}{$lhs} ) || next }; - # there is no way to know who is right and who is left - # therefore the ugly scan below + # there is no way to know who is right and who is left in a cref + # therefore a full blown resolution call # TEMP my $rel_rsrc = $self->related_source($args->{rel_name}); $colinfos ||= $storage->_resolve_column_info([ @@ -2125,9 +2125,7 @@ sub _resolve_relationship_condition { { -alias => $args->{foreign_alias}, -rsrc => $rel_rsrc }, ]); - my ($l_col, $l_alias, $r_col, $r_alias) = map { - ( reverse $_ =~ / ^ (?: ([^\.]+) $ | ([^\.]+) \. (.+) ) /x )[0,1] - } ($lhs, $rhs); + my ($l_col, $r_col) = map { $_ =~ / ([^\.]+) $ /x } ($lhs, $rhs); if ( $colinfos->{$l_col}