Skip to content

Commit

Permalink
Update home.page.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
DuduVerderio committed Sep 30, 2023
1 parent cbb85ad commit 9024930
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app/home/home.page.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component, ChangeDetectorRef } from '@angular/core';
import { Component, NgZone } from '@angular/core';

@Component({
selector: 'app-home',
Expand All @@ -11,7 +11,7 @@ export class HomePage {
precoGasolina = ""
public resultado: String = ""

constructor(private cdRef: ChangeDetectorRef) {}
constructor(private ngZone: NgZone) {}

ngOnInit(){
this.resultado = ""
Expand All @@ -36,7 +36,7 @@ export class HomePage {
this.resultado = "Os campos não foram preenchidos corretamente"
}

this.cdRef.detectChanges();
this.ngZone.run(() => {});
}

}

0 comments on commit 9024930

Please sign in to comment.