angular-multi-select icon indicating copy to clipboard operation
angular-multi-select copied to clipboard

Everything matches "object" in filter

Open gbassan opened this issue 7 years ago • 0 comments

If you type "object" into the filter box, nothing will be eliminated. I detected this in an older version, but the bug is still visible on the demo page, so I presume it's still broken in the latest version. This error is because Angular appends a "$$hashKey" value to objects in a list that are referenced by ng-repeat, and the value is a string that contains "object" as well as some numbers. The problem can be fixed (in older versions) by changing this line in the 'contains' filter: if(attr && attr.toUpperCase && attr.indexOf){ to: if(attr && attr.toUpperCase && attr.indexOf && key !== "$$hashKey"){

gbassan avatar Dec 14 '16 23:12 gbassan