[Catalyst-commits] r7384 - in Catalyst-Runtime/5.70/trunk: . lib
jrockway at dev.catalyst.perl.org
jrockway at dev.catalyst.perl.org
Sun Jan 13 22:45:36 GMT 2008
Author: jrockway
Date: 2008-01-13 22:45:35 +0000 (Sun, 13 Jan 2008)
New Revision: 7384
Modified:
Catalyst-Runtime/5.70/trunk/Changes
Catalyst-Runtime/5.70/trunk/lib/Catalyst.pm
Log:
encode unicode to utf8 by default (in finalize)
Modified: Catalyst-Runtime/5.70/trunk/Changes
===================================================================
--- Catalyst-Runtime/5.70/trunk/Changes 2008-01-13 22:07:03 UTC (rev 7383)
+++ Catalyst-Runtime/5.70/trunk/Changes 2008-01-13 22:45:35 UTC (rev 7384)
@@ -1,5 +1,9 @@
# This file documents the revision history for Perl extension Catalyst.
+5.7013
+ - convert perl characters to utf8 before output
+ (Catalyst::Plugin::Unicode no longer needed for output)
+
5.7012 2007-12-16 23:44:00
- Fix __PACKAGE__->config->{foo} = 'bar' case with subclassing
- Add Catalyst::Stats (Jon Schutz)
Modified: Catalyst-Runtime/5.70/trunk/lib/Catalyst.pm
===================================================================
--- Catalyst-Runtime/5.70/trunk/lib/Catalyst.pm 2008-01-13 22:07:03 UTC (rev 7383)
+++ Catalyst-Runtime/5.70/trunk/lib/Catalyst.pm 2008-01-13 22:45:35 UTC (rev 7384)
@@ -1335,6 +1335,11 @@
$c->log->error($error);
}
+ # utf8-encode the body (convert perl chars to utf8 on the wire)
+ if ( $c->response->{body} && utf8::is_utf8($c->response->{body}) ){
+ utf8::encode( $c->response->{body} );
+ }
+
# Allow engine to handle finalize flow (for POE)
if ( $c->engine->can('finalize') ) {
$c->engine->finalize($c);
More information about the Catalyst-commits
mailing list