From: Wallace Reis Date: Tue, 16 Sep 2008 13:14:20 +0000 (+0000) Subject: getting rid of warns about undefined value for accessor X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=069e49b68eab1cc0cd37afaa9a75b8f841fea9dd;p=dbsrgits%2FDBIx-Class-Historic.git getting rid of warns about undefined value for accessor --- diff --git a/lib/SQL/Translator/Parser/DBIx/Class.pm b/lib/SQL/Translator/Parser/DBIx/Class.pm index d4499aa..ef7c51f 100644 --- a/lib/SQL/Translator/Parser/DBIx/Class.pm +++ b/lib/SQL/Translator/Parser/DBIx/Class.pm @@ -149,7 +149,8 @@ sub parse { $fk_constraint = $rel_info->{attrs}{is_foreign_key_constraint}; } # it can not be multi - elsif ( $rel_info->{attrs}{accessor} eq 'multi' ) { + elsif ( $rel_info->{attrs}{accessor} + && $rel_info->{attrs}{accessor} eq 'multi' ) { $fk_constraint = 0; } # if indeed single, check if all self.columns are our primary keys.