From: Wallace Reis Date: Sat, 15 Jun 2013 16:41:23 +0000 (+0000) Subject: Revert "Unicode plugin - rework exception handler" X-Git-Tag: 5.90042~2 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=commitdiff_plain;h=f20ba798d3cd91a5df5a0fc1f18c2947348a2b93 Revert "Unicode plugin - rework exception handler" This reverts commit 4fb27043578a31f1ffd7498d1097c817a932d173. No longer need to warn instead of die for failed decoding/encoding process due 95c85a0e3248f73938388889b599c3ddf67ac4fd. --- diff --git a/lib/Catalyst/Plugin/Unicode/Encoding.pm b/lib/Catalyst/Plugin/Unicode/Encoding.pm index 6da27ad..2f2e8d5 100644 --- a/lib/Catalyst/Plugin/Unicode/Encoding.pm +++ b/lib/Catalyst/Plugin/Unicode/Encoding.pm @@ -175,8 +175,7 @@ sub _handle_param_unicode_decoding { sub handle_unicode_encoding_exception { my ( $self, $exception_ctx ) = @_; - $self->log->warn($exception_ctx->{error_msg}); - return $exception_ctx->{'param_value'}; + die $exception_ctx->{error_msg}; } 1; diff --git a/lib/Catalyst/Upgrading.pod b/lib/Catalyst/Upgrading.pod index 63861b4..3e2d9d0 100644 --- a/lib/Catalyst/Upgrading.pod +++ b/lib/Catalyst/Upgrading.pod @@ -32,12 +32,6 @@ UTF-8. We'll add it for you if you continue to use the stand alone plugin and we detect this, but this backwards compatibility shim will likely be removed in a few releases (trying to clean up the codebase after all). -B: One other difference between the cored plugin and the stand alone one -is that in core we no longer throw an exception when there's a decode failure -but instead log a warning. If you rely on exceptions for control flow, you -will need to override method C to die instead -of warning. Please let the dev team know if this is a problem for you. - If you have trouble with any of this, please bring it to the attention of the Catalyst maintainer group.