{"action":"created","issue":{"url":"https://api.github.com/repos/Medium/matador/issues/171","repository_url":"https://api.github.com/repos/Medium/matador","labels_url":"https://api.github.com/repos/Medium/matador/issues/171/labels{/name}","comments_url":"https://api.github.com/repos/Medium/matador/issues/171/comments","events_url":"https://api.github.com/repos/Medium/matador/issues/171/events","html_url":"https://github.com/Medium/matador/issues/171","id":161822337,"number":171,"title":"Parameter and wildcard matches are decodeURIed twice","user":{"login":"kylewm","id":950127,"avatar_url":"https://avatars.githubusercontent.com/u/950127?v=3","gravatar_id":"","url":"https://api.github.com/users/kylewm","html_url":"https://github.com/kylewm","followers_url":"https://api.github.com/users/kylewm/followers","following_url":"https://api.github.com/users/kylewm/following{/other_user}","gists_url":"https://api.github.com/users/kylewm/gists{/gist_id}","starred_url":"https://api.github.com/users/kylewm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kylewm/subscriptions","organizations_url":"https://api.github.com/users/kylewm/orgs","repos_url":"https://api.github.com/users/kylewm/repos","events_url":"https://api.github.com/users/kylewm/events{/privacy}","received_events_url":"https://api.github.com/users/kylewm/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2016-06-23T01:37:37Z","updated_at":"2016-06-24T17:16:27Z","closed_at":null,"body":"Tracking down [a bug in medium2](https://github.com/Medium/medium2/issues/33473#issuecomment-227917834), I noticed matador is unescaping parameters one too many times. For example, if \r\n\r\n1. there's a route `/dir/*` \r\n2. client wants to send the parameter `http://hi%5Ethere` \r\n3. client hits the path `/dir/http%3A%2F%2Fhi%255Ethere`\r\n4. matador tells me `*` is `http://hi^there` (`^` should be `%5E`)\r\n\r\nI added a test demonstrating: https://github.com/Medium/matador/compare/kylewm/over-decoding with the result:\r\n\r\n```\r\n✖ testNamedParameterEscaping\r\n\r\nAssertionError: 'hello%20world' == 'hello world'\r\n    at Object.equal (/Users/kylemahan/src/matador/node_modules/nodeunit/lib/types.js:83:39)\r\n    at /Users/kylemahan/src/matador/tests/functional/routing_test.js:17:10\r\n    ...\r\n\r\n✖ testWildcardEscaping\r\n\r\nAssertionError: 'http://example.com/abc%5E123' == 'http://example.com/abc^123'\r\n    at Object.equal (/Users/kylemahan/src/matador/node_modules/nodeunit/lib/types.js:83:39)\r\n    at /Users/kylemahan/src/matador/tests/functional/routing_test.js:31:10\r\n    ...\r\n```"},"comment":{"url":"https://api.github.com/repos/Medium/matador/issues/comments/228405533","html_url":"https://github.com/Medium/matador/issues/171#issuecomment-228405533","issue_url":"https://api.github.com/repos/Medium/matador/issues/171","id":228405533,"user":{"login":"nicks","id":278641,"avatar_url":"https://avatars.githubusercontent.com/u/278641?v=3","gravatar_id":"","url":"https://api.github.com/users/nicks","html_url":"https://github.com/nicks","followers_url":"https://api.github.com/users/nicks/followers","following_url":"https://api.github.com/users/nicks/following{/other_user}","gists_url":"https://api.github.com/users/nicks/gists{/gist_id}","starred_url":"https://api.github.com/users/nicks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicks/subscriptions","organizations_url":"https://api.github.com/users/nicks/orgs","repos_url":"https://api.github.com/users/nicks/repos","events_url":"https://api.github.com/users/nicks/events{/privacy}","received_events_url":"https://api.github.com/users/nicks/received_events","type":"User","site_admin":false},"created_at":"2016-06-24T17:16:26Z","updated_at":"2016-06-24T17:16:26Z","body":"published!\n\nOn Fri, Jun 24, 2016 at 12:56 PM, Kyle Mahan <notifications@github.com>\nwrote:\n\n> @majelbstoat <https://github.com/majelbstoat> @nicks\n> <https://github.com/nicks> thanks for taking a look! would you mind\n> releasing a new version on npm when you have a chance?\n>\n> —\n> You are receiving this because you were mentioned.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/Medium/matador/issues/171#issuecomment-228400417>, or mute\n> the thread\n> <https://github.com/notifications/unsubscribe/AARAcQE6cmrFlZyOTO5WWPQBoxWGWmigks5qPAxKgaJpZM4I8YHq>\n> .\n>\n"}}
{"actor":{"display_login":"nicks"}}