angular/packages/forms/src
Kristiyan Kostadinov 1d1304c70c fix(forms): error if control is removed as a result of another one being reset (#40462)
When a form is reset, it goes through `_forEachChild` to call `reset` on each of its children.
The problem is that if a control is removed while the loop is running (e.g. by a subscription),
the form will throw an error, because it built up the list of available control before the loop
started.

These changes fix the issue by adding a null check before invoing the callback.

Fixes #33401.

PR Close #40462
2021-01-19 11:41:23 -08:00
..
directives docs: remove duplicated the (#40434) 2021-01-14 11:33:57 -08:00
directives.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00
form_builder.ts docs: improve FormBuilder.group deprecation message (#39946) 2020-12-04 10:18:48 -08:00
form_providers.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00
forms.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00
model.ts fix(forms): error if control is removed as a result of another one being reset (#40462) 2021-01-19 11:41:23 -08:00
validators.ts docs(forms): typo word "property" was missing (#40323) 2021-01-06 08:44:03 -08:00
version.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00