Closed meslater1030 closed 4 years ago
@sumurthy or @Zlatkovsky can I get a review on this?
Hello, currently using this one and will appreciate merge it to master, thank you ahead. @meslater1030 @sumurthy @Zlatkovsky
Hey there @meslater1030 ,
Sorry for the noobish question but I am not very confortable with Git. Seems like your PR corrects a bug I have on IE and I would like to install your PR has a NPM dependency.
What is the correct npm command to do that?
Thank you, Denis
I'm also having issue which has an error saying:
unable to delete 'Microsoft' from storage
When will this fix be merged into master?
Adding @LouMM , @sumurthy as the maintainers of this repo.
It would be nice if this will work soon :)
I'm still having this problem. has Anyone a solution for that ?
Closing due to lack of response from maintainers.
This PR addresses issues #102 and #76 and it represents an alternative solution to PR #106.
When calling
get
on the TokenStorage class the method checks to see whether the token has expired. If the token has expired it callssuper.delete(tokenKey)
which lives on the parent Storage class. The Storage class delete method callsthis.get(tokenKey)
. Sincethis
in this case is the TokenStorage class we get an infinite recursion.I don't believe it's good practice to delete the expired token within the
get
method of the TokenStorage class since it's a side effect. If the token is expired then subsequent actions should be left to the caller. The authenticator appears to be the only caller of this method within the library and so I've updated that code to delete expired tokens if necessary. I'm aware this is a public method on TokenStorage and I'm open to suggestions about other possible alterations if this represents a breaking change for end users. However - it appears that the check for an expired token is the only additional functionality TokenStorage provides and since it does that in a way that fundamentally does not work I suspect this is a net gain.I've added tests for the change.
I've also updated the typings for tapable as per the recommendations here: https://github.com/webpack/tapable/issues/53. A new install of this project otherwise throws errors.
Finally, my tests revealed that the reviver deserializer in the Storage class relies on an outdated REGEX matcher for ISO strings. I've updated that as well.
Thanks for your help and let me know if you have any questions.