Skip to content

for(var x in array) is broken with this pollyfill. #2

Description

@sgtwilko

The current method of attaching the find function causes all arrays to seem to have an extra item when using for(var x in y).

e.g. the following is run in the IE console shown with the output :

f=[1,2,3,4]
> [object Array] [1, 2, 3, 4]

for(var x in f){console.log(x)}
> 0
> 1
> 2
> 3
> find

I have a fix which I'll be sending on a pull request.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions