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

Ensure getPrototypeOf will not crash on plugin options with no scopes #9431

Merged
merged 2 commits into from
Jul 24, 2021

Conversation

etimberg
Copy link
Member

Resolves #9368

@etimberg etimberg added this to the Version 3.5.0 milestone Jul 18, 2021
Copy link
Member

@kurkle kurkle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getOwnPropertyDescriptor also uses scopes[0].

In my opinion this dummy scope should be created in getOptionScopes when there are no other scopes. Does that make something fail?

@etimberg
Copy link
Member Author

No, I haven't tried that. That looks like a better solution, so I'll explore it

@kurkle
Copy link
Member

kurkle commented Jul 23, 2021

No, I haven't tried that. That looks like a better solution, so I'll explore it

Did you forget this, or just busy? :)

@etimberg
Copy link
Member Author

Totally forgot! Will try and get to this today

@kurkle kurkle merged commit d0eac36 into chartjs:master Jul 24, 2021
@blackmagic0
Copy link

blackmagic0 commented Sep 26, 2022

@etimberg Hey was this fix reverted? It doesn't seem to exist in the project, and I cant find the commit in the commit history for src/helpers/helpers.config.js

I get the same issue this fix addressed while using chart.js in AlpineJs.

I re-introduced it locally in my project and it did resolve the problem for me.

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

Successfully merging this pull request may close these issues.

"TypeError: Reflect.getPrototypeOf called on non-object" with local plugins
3 participants