summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2009-06-22 11:58:12 -0500
committerJesse Luehrs <doy@tozt.net>2009-06-22 11:58:12 -0500
commit6c05f99311697c600172be159d0aa7d72144640a (patch)
treede77748735d81bc68a9d1d7602be102bfca1ab70 /lib
parent62eab4ab4c140c8916539d4340afe29bdab01853 (diff)
downloadmoosex-nonmoose-6c05f99311697c600172be159d0aa7d72144640a.tar.gz
moosex-nonmoose-6c05f99311697c600172be159d0aa7d72144640a.zip
only call FOREIGNBUILDARGS if it's defined in the class (not superclasses)
Diffstat (limited to 'lib')
-rw-r--r--lib/MooseX/NonMoose/Meta/Role/Constructor.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/MooseX/NonMoose/Meta/Role/Constructor.pm b/lib/MooseX/NonMoose/Meta/Role/Constructor.pm
index 7b657e4..9733c3d 100644
--- a/lib/MooseX/NonMoose/Meta/Role/Constructor.pm
+++ b/lib/MooseX/NonMoose/Meta/Role/Constructor.pm
@@ -55,7 +55,7 @@ sub _generate_instance {
my $new = $self->name;
my $meta = $self->associated_metaclass;
my $super_new_class = $meta->find_next_method_by_name($new)->package_name;
- my $arglist = $meta->find_method_by_name('FOREIGNBUILDARGS')
+ my $arglist = $meta->get_method('FOREIGNBUILDARGS')
? "${class_var}->FOREIGNBUILDARGS(\@_)"
: '@_';
# XXX: this should probably be taking something from the meta-instance api,