Decoding utf-8 encoded parameters #2

merged 2 commits into from Aug 2, 2012


None yet
2 participants

losomo commented Jul 31, 2012

WebNano encodes the message body to utf8, which is fine. However, the behavior should become symmetric, i.e. decoding request parameters in Plack::Request. The same operation in Tatsumaki framework looks like this:

Since WebNano doesn't subclass Plack::Request, I am decoding the parameters just after creating the Plack::Request object.

Without this modification, applications would have to decode all parameters all over the place whenever they are used.


zby commented Jul 31, 2012

Thanks for the patch! Sounds reasonable - let me sleep with it and test it with Nblog. Could you add some tests as well?


losomo commented Jul 31, 2012

Good idea. They are included.

zby added a commit that referenced this pull request Aug 2, 2012

Merge pull request #2 from losomo/master
Decoding utf-8 encoded parameters

@zby zby merged commit 0221962 into zby:master Aug 2, 2012


zby commented Aug 2, 2012

Thanks again! By the way it also need some documentation. I am going on vacations tomorrow - so don't expect quick responses.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment