Skip to content

Commit

Permalink
dont emit event when injecting
Browse files Browse the repository at this point in the history
  • Loading branch information
wouter-willems committed Aug 9, 2024
1 parent dea3dde commit 667cff4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion projects/klippa/ngx-enhancy-forms/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@klippa/ngx-enhancy-forms",
"version": "14.22.14",
"version": "14.22.15",
"publishConfig": {
"access": "public"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export class FormComponent implements OnInit, OnDestroy, OnChanges {
}
const valueBeforeInject = injectInto.at(injectAt)?.value;
if (isValueSet(valueBeforeInject)) {
this.formGroup.patchValue(valueBeforeInject);
this.formGroup.patchValue(valueBeforeInject, { emitEvent: false });
}
injectInto.setControl(injectAt, this.formGroup);
this.onInjected.emit(valueBeforeInject);
Expand All @@ -80,7 +80,7 @@ export class FormComponent implements OnInit, OnDestroy, OnChanges {
}
const valueBeforeInject = injectInto.get(injectAt)?.value;
if (isValueSet(valueBeforeInject)) {
this.formGroup.patchValue(valueBeforeInject);
this.formGroup.patchValue(valueBeforeInject, {emitEvent: false});
}
injectInto.setControl(injectAt, this.formGroup);
this.onInjected.emit(valueBeforeInject);
Expand Down

0 comments on commit 667cff4

Please sign in to comment.