X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst.pm;h=6d77f40f1ea0645377c2817bae0b609f0c627fde;hb=b677b4c22739a063c230215b59c37a8e4e3e9a0e;hp=bfa22a699c167ed883273710cc5e80fb7aec96a2;hpb=0bab6d6c644cf9d0988d4b5bf0afec572e3f1719;p=catagits%2FCatalyst-Runtime.git diff --git a/lib/Catalyst.pm b/lib/Catalyst.pm old mode 100644 new mode 100755 index bfa22a6..6d77f40 --- a/lib/Catalyst.pm +++ b/lib/Catalyst.pm @@ -126,7 +126,7 @@ __PACKAGE__->stats_class('Catalyst::Stats'); # Remember to update this in Catalyst::Runtime as well! -our $VERSION = '5.90059_004'; +our $VERSION = '5.90060'; sub import { my ( $class, @arguments ) = @_; @@ -1133,14 +1133,6 @@ sub setup { $class->setup_log( delete $flags->{log} ); $class->setup_plugins( delete $flags->{plugins} ); - # Call plugins setup, this is stupid and evil. - # Also screws C3 badly on 5.10, hack to avoid. - { - no warnings qw/redefine/; - local *setup = sub { }; - $class->setup unless $Catalyst::__AM_RESTARTING; - } - $class->setup_middleware(); $class->setup_data_handlers(); $class->setup_dispatcher( delete $flags->{dispatcher} ); @@ -1174,6 +1166,14 @@ You are running an old script! EOF } + # Call plugins setup, this is stupid and evil. + # Also screws C3 badly on 5.10, hack to avoid. + { + no warnings qw/redefine/; + local *setup = sub { }; + $class->setup unless $Catalyst::__AM_RESTARTING; + } + # Initialize our data structure $class->components( {} ); @@ -1254,7 +1254,7 @@ EOF # Should be the last thing we do so that user things hooking # setup_finalize can log.. $class->log->_flush() if $class->log->can('_flush'); - return 1; # Explicit return true as people have __PACKAGE__->setup as the last thing in their class. HATE. + return $class || 1; # Just in case someone named their Application 0... } =head2 $app->setup_finalize