Merge branch 'patch-1' of https://github.com/daleevans/catalyst-runtime into daleevan...
John Napiorkowski [Wed, 22 Jul 2015 17:19:47 +0000 (12:19 -0500)]
1  2 
lib/Catalyst.pm

diff --combined lib/Catalyst.pm
@@@ -180,7 -180,7 +180,7 @@@ sub composed_stats_class 
  __PACKAGE__->_encode_check(Encode::FB_CROAK | Encode::LEAVE_SRC);
  
  # Remember to update this in Catalyst::Runtime as well!
 -our $VERSION = '5.90092';
 +our $VERSION = '5.90093';
  $VERSION = eval $VERSION if $VERSION =~ /_/; # numify for warning-free dev releases
  
  sub import {
@@@ -521,7 -521,7 +521,7 @@@ L<< detach|/"$c->detach( $action [, \@a
  C<< $c->go >> will perform a full dispatch on the specified action or method,
  with localized C<< $c->action >> and C<< $c->namespace >>. Like C<detach>,
  C<go> escapes the processing of the current request chain on completion, and
- does not return to its cunless blessed $cunless blessed $caller.
+ does not return to its caller.
  
  @arguments are arguments to the final destination of $action. @captures are
  arguments to the intermediate steps, if any, on the way to the final sub of
@@@ -2228,10 -2228,9 +2228,10 @@@ sub finalize_encoding 
          # Set the charset if necessary.  This might be a bit bonkers since encodable response
          # is false when the set charset is not the same as the encoding mimetype (maybe 
          # confusing action at a distance here..
 -        # Don't try to set the charset if one already exists
 +        # Don't try to set the charset if one already exists or if headers are already finalized
          $c->res->content_type($c->res->content_type . "; charset=" . $c->encoding->mime_name)
 -          unless($c->res->content_type_charset);
 +          unless($c->res->content_type_charset ||
 +                ($c->res->_context && $c->res->finalized_headers && !$c->res->_has_response_cb));
      }
  }