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

jsref_unescape can not decode chinese word #280

Open
fewiki opened this issue May 7, 2018 · 3 comments
Open

jsref_unescape can not decode chinese word #280

fewiki opened this issue May 7, 2018 · 3 comments

Comments

@fewiki
Copy link

fewiki commented May 7, 2018

The unescape() function was deprecated in JavaScript version 1.5. Use decodeURI() or decodeURIComponent() instead.

The unescape() function decodes an encoded string.

https://www.w3schools.com/jsref/jsref_unescape.asp

Can you update the lib? change the unescape function. thanks~~

// in cookieStore.js
function read(key) {
	if (!key || !_has(key)) { return null }
	var regexpStr = "(?:^|.*;\\s*)" +
		escape(key).replace(/[\-\.\+\*]/g, "\\$&") +
		"\\s*\\=\\s*((?:[^;](?!;))*[^;]?).*"
	return unescape(doc.cookie.replace(new RegExp(regexpStr), "$1"))
}
@jerdeboer
Copy link

Any chance explaining how you got around this, the values in local storage are all in Chinese Characters

@iongion
Copy link

iongion commented Jun 20, 2018

I am having the same issue, I initially thought the project got hacked

@iongion
Copy link

iongion commented Jun 20, 2018

Created an issue for this only #283 ... maybe a duplicate

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