# This file documents the revision history for Perl extension Catalyst.
+5.90017 - 2012-10-19 22:33:00
+ - Change Catalsyt _parse_attrs so that when sub attr handlers:
+
+ 1) Can return multiple pairs of new attributes.
+ 2) Get their returned attributes passed through the correct attribute handler.
+
+ e.g sub _parse_Whatever_attr { return Chained => 'foo', PathPart => 'bar' }
+
+ Will now work because both new attributes are respected, and the Chained
+ attribute is passed to _parse_Chained_attr and fixed up correctly by that.
+
+ - In Catalyst::Test, don't mangle headers of non-HTML responses. RT#79043
+
+ - Refactor request and response class construction to add methods
+ that roles can hook to feed extra parameters into the constructor
+ of request or response classes.
+
5.90016 - 2012-08-16 15:35:00
- prepare_parameters is no longer an attribute builder. It is now a method
that calls the correct underlying functionality (Bill Moseley++)
is => 'rw',
default => sub {
my $self = shift;
- my %p = ( _log => $self->log );
- $p{_uploadtmp} = $self->_uploadtmp if $self->_has_uploadtmp;
- $self->request_class->new(\%p);
+ $self->request_class->new($self->_build_request_constructor_args);
},
lazy => 1,
);
+sub _build_request_constructor_args {
+ my $self = shift;
+ my %p = ( _log => $self->log );
+ $p{_uploadtmp} = $self->_uploadtmp if $self->_has_uploadtmp;
+ \%p;
+}
+
has response => (
is => 'rw',
default => sub {
my $self = shift;
- $self->response_class->new({ _log => $self->log });
+ $self->response_class->new($self->_build_response_constructor_args);
},
lazy => 1,
);
+sub _build_response_constructor_args {
+ my $self = shift;
+ { _log => $self->log };
+}
+
has namespace => (is => 'rw');
sub depth { scalar @{ shift->stack || [] }; }
# Remember to update this in Catalyst::Runtime as well!
-our $VERSION = '5.90016';
+our $VERSION = '5.90017';
sub import {
my ( $class, @arguments ) = @_;
my $attributes = $method->can('attributes') ? $method->attributes : [];
my $attrs = $self->_parse_attrs( $c, $name, @{ $attributes } );
if ( $attrs->{Private} && ( keys %$attrs > 1 ) ) {
- $c->log->debug( 'Bad action definition "'
+ $c->log->warn( 'Bad action definition "'
. join( ' ', @{ $attributes } )
. qq/" for "$class->$name"/ )
if $c->debug;
# Remember to update this in Catalyst as well!
-our $VERSION = '5.90016';
+our $VERSION = '5.90017';
=head1 NAME