mirror of
https://github.com/bitwarden/browser.git
synced 2025-01-09 19:28:06 +01:00
Confirmed inline form errors working and removing todo comments.
This commit is contained in:
parent
4f11c2c914
commit
f42a391b6f
@ -180,21 +180,6 @@ export class LoginComponent implements OnInit, OnDestroy {
|
|||||||
|
|
||||||
await this.setupCaptcha();
|
await this.setupCaptcha();
|
||||||
|
|
||||||
/**
|
|
||||||
* TODO-rr-bw: Verify the following
|
|
||||||
*
|
|
||||||
* In the original base login component there is a comment in the submit() method that says:
|
|
||||||
* "desktop, browser; This should be removed once all clients use reactive forms"
|
|
||||||
*
|
|
||||||
* Since we are now using reactive forms for all clients. I removed the Browser/Desktop specific
|
|
||||||
* toast error message.
|
|
||||||
*
|
|
||||||
* I also removed the `showToast` parameter from the submit() method entirely because my
|
|
||||||
* understanding is that now all errors will be visually handled by the reactive form via
|
|
||||||
* this.formGroup.markAllAsTouched()
|
|
||||||
*
|
|
||||||
* Therefore below I am simply checking if the form is invalid and returning if so.
|
|
||||||
*/
|
|
||||||
this.formGroup.markAllAsTouched();
|
this.formGroup.markAllAsTouched();
|
||||||
if (this.formGroup.invalid) {
|
if (this.formGroup.invalid) {
|
||||||
return;
|
return;
|
||||||
@ -538,13 +523,6 @@ export class LoginComponent implements OnInit, OnDestroy {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
|
||||||
* TODO-rr-bw: Verify the following
|
|
||||||
*
|
|
||||||
* In the original web login component, this following code is called AFTER the base ngOnInit()
|
|
||||||
* runs. Verify that that previous order was not necessary, and that I can place all webOnInit()
|
|
||||||
* logic here BEFORE the defaultOnInit() call.
|
|
||||||
*/
|
|
||||||
// If there's an existing org invite, use it to get the password policies
|
// If there's an existing org invite, use it to get the password policies
|
||||||
const orgPolicies = await this.loginComponentService.getOrgPolicies();
|
const orgPolicies = await this.loginComponentService.getOrgPolicies();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user