Hi guys,
I've encountered a regression in DBIC, introduced in revision 5298.
It's more than likely that the way things were being done in the code
here were not correct and *shouldn't* have worked previously, but I
can't seem to work it out myself.
There's a single changed line which triggers the problem:
--------------------------------------------------------
diff --git a/lib/DBIx/Class/Schema.pm b/lib/DBIx/Class/Schema.pm
@@ -1228,7 +1229,7 @@ sub register_extra_source {
sub _register_source {
my ($self, $moniker, $source, $params) = @_;
- %$source = %{ $source->new( { %$source, source_name => $moniker }) };
+ $source = $source->new({ %$source, source_name => $moniker });
--------------------------------------------------------
I've created a small unit test that demonstrates the issue, here:
http://dryft.net/dbic/tobyc-dbic-problem.tar.gz
The failure manifests itself as missing relationships on the result
sources. They're clearly setup, and it all works fine until the above
line is changed in DBIC/Schema.pm.
Any help would be most appreciated.
Cheers,
Toby
_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/[email protected]