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

Object.keys polyfill has wrong check condition #9

Closed
kremso opened this issue Jul 18, 2014 · 2 comments
Closed

Object.keys polyfill has wrong check condition #9

kremso opened this issue Jul 18, 2014 · 2 comments

Comments

@kremso
Copy link

kremso commented Jul 18, 2014

The generated code is

if (typeof Object === "undefined" || Object && !Object.keys) {
// Object.keys
Object.keys = function keys(object) {
        // code here
};
}

However, when Object is undefined, you cannot add properties to it.

azproduction added a commit that referenced this issue Jul 19, 2014
@azproduction
Copy link
Owner

Thank you @kremso, what a terrible mistake. #10

@azproduction
Copy link
Owner

autopolyfiller@1.1.2

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

2 participants