]> git.decadent.org.uk Git - maypole.git/blobdiff - lib/Maypole.pm
possible fix for components, added another test to MANIFEST
[maypole.git] / lib / Maypole.pm
index 7b17858b849ffdd4fa9c63374e09ee215db0df07..59b519706c939f83fb774b16d685295fe88e5a4e 100644 (file)
@@ -275,7 +275,7 @@ documentation. However here is the most usage of setup where
 Maypole::Model::CDBI is the base class.
 
  My::App->setup($data_source, $user, $password,
-       {  opitons => {  # These are DB connection options
+       {  options => {  # These are DB connection options
                AutoCommit => 0,
                RaiseError => 1,
                ...
@@ -487,8 +487,9 @@ You should not fully qualify the Maypole URLs.
 
 sub component {
     my ( $r, $path ) = @_;
-    my $self = bless { parent => $r }, ref $r;
+    my $self = bless { parent => $r, config => $r->{config} }, ref $r;
     my $url = URI->new($path);
+    warn "path : $path\n";
     $self->{path} = $url->path;
     $self->parse_path;
     $self->params( $url->query_form_hash );
@@ -592,7 +593,7 @@ sub handler_guts
       if ( my $error = $@ ) 
         {
          $status = $self->call_exception($error, "model");
-         if ( $status != OK ) 
+         if ( $status != OK )
             {
              warn "caught model error: $error";
              return $self->debug ?