incorporated static discussion from andyg into Cookbook.pod
[catagits/Catalyst-Runtime.git] / lib / Catalyst.pm
index 7523068..2c6ca19 100644 (file)
@@ -13,7 +13,7 @@ our $CATALYST_SCRIPT_GEN = 4;
 
 __PACKAGE__->mk_classdata($_) for qw/arguments dispatcher engine log/;
 
-our $VERSION = '5.24';
+our $VERSION = '5.31';
 our @ISA;
 
 =head1 NAME
@@ -126,17 +126,16 @@ Returns a hashref containing your applications settings.
 
 sub import {
     my ( $class, @arguments ) = @_;
-
+    
+    # We have to limit $class to Catalyst to avoid pushing Catalyst upon every
+    # callers @ISA.
     return unless $class eq 'Catalyst';
 
     my $caller = caller(0);
-    
-    # Prepare inheritance
-    unless ( $caller->isa($class) ) {
-        
+
+    unless ( $caller->isa('Catalyst') ) {
         no strict 'refs';
         push @{"$caller\::ISA"}, $class;
-        
     }
 
     $caller->arguments( [ @arguments ] );