docs and ready for release testing
John Napiorkowski [Wed, 7 Jan 2015 22:44:04 +0000 (16:44 -0600)]
Changes
lib/Catalyst.pm
lib/Catalyst/Response.pm
lib/Catalyst/Runtime.pm

diff --git a/Changes b/Changes
index a91032d..2e1912a 100644 (file)
--- a/Changes
+++ b/Changes
@@ -4,7 +4,7 @@
   - If we get a response set from $res->from_psgi_response and that response
     has a charset for the content type, we clear encoding for the rest of the
     response (avoid double encoding).
-  -
+  - Documentation updates and typo fixes across various UTF8 docs (Mark Ellis++)
 
 5.90079_007  - 2015-01-07
   - Merged from Stable (5.90079)
index f3f86f2..dede663 100644 (file)
@@ -129,7 +129,7 @@ __PACKAGE__->stats_class('Catalyst::Stats');
 __PACKAGE__->_encode_check(Encode::FB_CROAK | Encode::LEAVE_SRC);
 
 # Remember to update this in Catalyst::Runtime as well!
-our $VERSION = '5.90079_007';
+our $VERSION = '5.90079_008';
 $VERSION = eval $VERSION if $VERSION =~ /_/; # numify for warning-free dev releases
 
 sub import {
@@ -3632,7 +3632,7 @@ sub default_data_handlers {
           return eval { 
             local $/;
             $slurped = $fh->getline;
-            $parser->can("decode_json")->($slurped);
+            $parser->can("decode_json")->($slurped); # decode_json does utf8 decoding for us
           } || Catalyst::Exception->throw(sprintf "Error Parsing POST '%s', Error: %s", (defined($slurped) ? $slurped : 'undef') ,$@);
         },
     };
index b27da58..a3580ff 100644 (file)
@@ -169,6 +169,8 @@ sub from_psgi_response {
     # to assume its properly encoded and NOT encode for this response.  Otherwise
     # We risk double encoding.
     if($self->content_type_charset) {
+      # We have to do this since for backcompat reasons having a charset doesn't always
+      # mean that the body is already encoded :(
       $self->_context->clear_encoding;
     }
 }
index a4e2346..1cd18a6 100644 (file)
@@ -7,7 +7,7 @@ BEGIN { require 5.008003; }
 
 # Remember to update this in Catalyst as well!
 
-our $VERSION = '5.90079_007';
+our $VERSION = '5.90079_008';
 $VERSION = eval $VERSION if $VERSION =~ /_/; # numify for warning-free dev releases
 
 =head1 NAME