Fix bugs introduced previously
[catagits/CatalystX-DynamicComponent.git] / lib / CatalystX / DynamicComponent / ModelToControllerReflector.pm
index 01883b5..c9f3877 100644 (file)
@@ -59,7 +59,7 @@ sub _reflect_model_to_controller {
     $strategy->new;
 
     my $model_methods = $model->meta->get_method_map;
-    foreach my $method_name ( $strategy->get_reflected_method_list($app, $model->meta) ) {
+    foreach my $method_name ( $strategy->get_reflected_method_list($app, $model_name) ) {
         # Note need to pass model name, as the method actually comes from
         # the underlying model class, not the Catalyst shim class we autogenerated.
         $controller_methods{$method_name} =