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

TypeError: decodeComponents(...).join is not a function #5

Closed
KatsuragiCSL opened this issue Aug 24, 2022 · 2 comments
Closed

TypeError: decodeComponents(...).join is not a function #5

KatsuragiCSL opened this issue Aug 24, 2022 · 2 comments

Comments

@KatsuragiCSL
Copy link

Crash occured when %ea%ba%5a%ba is parsed by decodeUriComponent

This function is used in some other nodejs projects for decoding query strings and hash strings in url, for example the hash # kun%ea%ba%5a%ba is valid and should be parsed correctly as { ' kun%ea%ba%5a%ba': null }

For example in chrome's development tools' console the url https://google.com# kun%ea%ba%5a%ba can be parsed without problems:

const url = new URL("https://google.com#  kun%ea%ba%5a%ba");
url

image

Code to reproduce

const decodeUriComponent = require('decode-uri-component');

var x = decodeUriComponent('%ea%ba%5a%ba');

console.log(x);

Results

TypeError: decodeComponents(...).join is not a function

@SamVerschueren
Copy link
Owner

This is now fixed in v0.2.1.

@furious-fury
Copy link

This is now fixed in v0.2.1.

I somehow haven't seen the update

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

No branches or pull requests

3 participants