EditableColumn: error in ngOnChanges when input other than data changes #15657
Labels
Status: Needs Triage
Issue will be reviewed by Core Team and a relevant label will be added as soon as possible
Describe the bug
In Reference to this issue #14525 which was fixed for 17 version. I am facing same issue on version 16 now
When value of any input attribute such as pEditableColumnDisabled changes during runtime, an error is thrown due to change.data being undefined.
I believe that error is in:
primeng/src/app/components/table/table.ts
Line 4067 in 8c9f3d0
if (this.el.nativeElement && !data.firstChange) {
Which assumes that property data of SimpleChanges object will be always defined, which is not true when only the pEditableColumnDisabled input changes (f.e. with slight delay).
Environment
unrelated
Reproducer
https://stackblitz.com/edit/github-8qgwug-rbxqag?file=src%2Fapp%2Fapp.component.html
Angular version
16.2.12
PrimeNG version
16.9.1
Build / Runtime
Angular CLI App
Language
TypeScript
Node version (for AoT issues node --version)
18.10.0
Browser(s)
No response
Steps to reproduce the behavior
Open example, click enable editing.
Expected behavior
No error should be thrown on console when any input attribute changes on editable column
The text was updated successfully, but these errors were encountered: