Merge pull request 'fix: update returnUrl handling and navigation in OtpComponent' (#4) from task/popup-for-dynamic-form into develop
Reviewed-on: #4
This commit is contained in:
commit
7d707051d5
@ -19,7 +19,7 @@ export class OtpComponent implements OnInit {
|
||||
message = signal('');
|
||||
countdown = signal(0);
|
||||
timer: NodeJS.Timeout | undefined;
|
||||
returnUrl = '/';
|
||||
returnUrl = '';
|
||||
fb: FormBuilder = inject(FormBuilder);
|
||||
authService: AuthService = inject(AuthService);
|
||||
router: Router = inject(Router);
|
||||
@ -35,13 +35,13 @@ export class OtpComponent implements OnInit {
|
||||
});
|
||||
|
||||
if(this.authService.isLoggedIn()){
|
||||
this.router.navigateByUrl('/');
|
||||
this.router.navigate(['']);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
ngOnInit() {
|
||||
this.returnUrl = this.route.snapshot.queryParamMap.get('returnUrl') || '/';
|
||||
this.returnUrl = this.route.snapshot.queryParamMap.get('returnUrl') || '';
|
||||
}
|
||||
|
||||
sendOtp() {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user