Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Case class requests with url encoded route params are not decoded #427

Closed
devshorts opened this issue Aug 3, 2017 · 3 comments
Closed

Comments

@devshorts
Copy link

devshorts commented Aug 3, 2017

If you have a case class request:

case class FooRequest(@RouteParam data: String)

And a controller like:

get("test/:dat") { request: FooRequest => 
}

If you send a url encoded route to it:

get test/=
GET test/%3D`

The value of data does not reflect the decoded value (=) but instead shows %3D. This seems related to #68 but was filed against 1.x and I am seeing this on finatra 2.10

Expected behavior

Route url encoded params are decoded

Actual behavior

Route url encoded params are not decoded

@cacoco
Copy link
Contributor

cacoco commented Aug 22, 2017

Related to #296

@vkostyukov
Copy link
Contributor

We have a fix for this internally. Watch this space.

finaglehelper pushed a commit that referenced this issue May 7, 2019
Problem

Route params are extracted as is forcing users to do URL-decoding themselves (if needed).

Solution

URL-decode route params automatically in Finatra.

Github issue: #427

JIRA Issues: CSL-4998

Differential Revision: https://phabricator.twitter.biz/D309144
@vkostyukov
Copy link
Contributor

Fixed in a79f563.

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

No branches or pull requests

3 participants