Skip to content

FilterOptions break with some internal undefined #410

Description

@sospedra

So, if I set up the filterOptions like this (really dummy test, it just remove all the default filters):

filter: function (options, filter, currentValues) {
     return options
}

It breaks and prompt this error:
Uncaught TypeError: Cannot read property 'length' of undefined

This piece of code:

getFirstFocusableOption: function getFirstFocusableOption(options) {
    for (var optionIndex = 0; optionIndex < options.length; ++optionIndex) {
        if (!options[optionIndex].disabled) {
            return options[optionIndex];
        }
    }
},

I've followed the stacktrace and it's always undefined.

Any idea?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions