From: Alexander Hartmaier Date: Fri, 16 Mar 2012 13:25:10 +0000 (+0100) Subject: first take at has_relationship_loaded X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=75486db1708d84deec39d10c86df51fa06be73b5;p=dbsrgits%2FDBIx-Class.git first take at has_relationship_loaded --- diff --git a/lib/DBIx/Class/Row.pm b/lib/DBIx/Class/Row.pm index 2cc5739..12e9b5f 100644 --- a/lib/DBIx/Class/Row.pm +++ b/lib/DBIx/Class/Row.pm @@ -714,7 +714,7 @@ sub has_relationship_loaded { $self->throw_exception( "has_relationship_loaded needs a relationship name" ) unless defined $rel; - return 0; + return exists $self->{related_resultsets}->{$rel}; } =head2 get_columns