-
Notifications
You must be signed in to change notification settings - Fork 687
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
loadUserProfile() no longer typesafe #1144
Comments
That's a good question indeed! I do not have the answer. I did trace it to the changes (amongst others) here: bbff95b#diff-685e26c24f3c008856834f8b4a350d5472b6aea01a623c31a8513f6cc599c57fL722-R722 In that PR I also see an open comment (from after the commits were made I think) saying something similar. |
@jeroenheijmans Yes, i traced it back to that too and was relieved that I wasn't the only one having problems with this change. |
…t opens multiple popup instead of focusing already opened
We actually ran into this when upgrading the library in one of our applications. At this point it's probably not useful to revert this breaking change anymore. However, I think it would be good to have the README and relevant release notes mention that the data from return this.oAuthService.loadUserProfile()
.then((userProfile: Record<string, unknown>) => {
const user = new User(userProfile?.info); |
I just upgraded to version 12 and face an issue with loading the userinfo.
After PR #939 the return type of
loadUserProfile()
changed fromUserinfo
toUserinfo | string
and now toobject
.I thought, I could still at least cast to Userinfo, but weirdly the response is wrapped like this:
instead of
so that I would have to call
I would really like to find a cleaner solution to this.
Is the response wrapped in "info" on purpose?
And why did the response type change from
Userinfo | string
toobject
?The text was updated successfully, but these errors were encountered: