braintree / sanitize-url

MIT License
312 stars 35 forks source link

Accents are stripped out #20

Closed edwinjoseph closed 4 years ago

edwinjoseph commented 4 years ago

Description

When trying to sanitize urls if the url has accented characters in them they get dropped.

Update:

Here is a PR that I've create with a possible solution: https://github.com/edwinjoseph/sanitize-url/pull/1

Current Behaviour

  sanitizeUrl('https://www.somedomain.com/posts/a-new-post-with-asšês');
  // => https://www.somedomain.com/posts/a-new-post-with-ass

Expected Behaviour

  sanitizeUrl('https://www.somedomain.com/posts/a-new-post-with-asšês');
  // => https://www.somedomain.com/posts/a-new-post-with-asšês
crookedneighbor commented 4 years ago

Go ahead and open the PR here instead of on your fork and we'll evaluate it. Thanks!

crookedneighbor commented 4 years ago

Fixed with 4.0.1