X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=lib%2FMaypole%2FModel%2FCDBI%2FAsForm.pm;fp=lib%2FMaypole%2FModel%2FCDBI%2FAsForm.pm;h=2c5f60df019b7f82d0475a861ca277486a87b10e;hb=1abc072646e8d37a20ee85c8ca6bb548e2176027;hp=9beaa8dc7288af5a50a6545b623cb2cb116bd5fd;hpb=e1ed80e9b0929d184fabfb6d4df9a8db4580eb4e;p=maypole.git diff --git a/lib/Maypole/Model/CDBI/AsForm.pm b/lib/Maypole/Model/CDBI/AsForm.pm index 9beaa8d..2c5f60d 100644 --- a/lib/Maypole/Model/CDBI/AsForm.pm +++ b/lib/Maypole/Model/CDBI/AsForm.pm @@ -983,7 +983,9 @@ sub _to_foreign_inputs { } # Ignore our fkey in them to prevent infinite recursion - my $me = eval {$rel_meta->{args}{foreign_column}} || ''; + my $me = eval {$rel_meta->{args}{foreign_key}} || + eval {$rel_meta->{args}{foreign_column}} + || ''; # what uses foreign_column has_many or might_have my $constrained = $rel_meta->{args}{constraint}; my %inputs; foreach ( @$fields ) {