You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
When using filter (filterFilter function) with deep object and optional properties (means nullable), filter throws an error "TypeError: Cannot read property 'x' of null '
I believe that a null value property check is missing when dealing with object
By the way the orderBy filter is not concerned by this issue.
I solved it in my project by replacing the following line in the deepCompare function used by filterFilter function.
varactualVal=matchAnyProperty ? actual : actual[key];
with
varactualVal=(matchAnyProperty||actual==null) ? actual : actual[key];
… when using objects with filter
fix(filterFilter): solve issue angular#10991 with null property value when using objects with filter
Regarding the issue angular#10991 and the following discussion angular#10992
When using filter (filterFilter function) with deep object and optional properties (means nullable), filter throws an error "TypeError: Cannot read property 'x' of null '
I believe that a null value property check is missing when dealing with object
By the way the orderBy filter is not concerned by this issue.
I solved it in my project by replacing the following line in the deepCompare function used by filterFilter function.
with
The issue is on
actual[key]
Angular version : 1.3.12
Reproducible: Always
Jsfiddle : http://jsfiddle.net/k25y4bg2/
The text was updated successfully, but these errors were encountered: