Commit 35dad5c
committed
fix(query-builder): prevent error when entities are empty and expressionTree is set
getFormat() was calling .pipeArgs.format without optional chaining after
find(), causing Angular's ngFormatDate to receive undefined as the format
string (TypeError: Cannot read properties of undefined (reading 'length'))
when fields is null due to an empty entities array. Added full optional
chaining and a DEFAULT_PIPE_DATE_FORMAT fallback.1 parent 2f824cb commit 35dad5c
2 files changed
Lines changed: 2 additions & 1 deletion
File tree
- projects/igniteui-angular/query-builder/src/query-builder
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1380 | 1380 | | |
1381 | 1381 | | |
1382 | 1382 | | |
1383 | | - | |
| 1383 | + | |
1384 | 1384 | | |
1385 | 1385 | | |
1386 | 1386 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| 31 | + | |
31 | 32 | | |
32 | 33 | | |
33 | 34 | | |
| |||
0 commit comments