-
Exception message and full stack trace: ERROR TypeError: Cannot read properties of undefined (reading 'isInternalAuth') at get isInternalAuth (abp-ng.oauth.mjs:489:26)
-
Steps to reproduce the issue: Previously working password reset flow is not working anymore after updating abp to 9.1.1 from 9.0.5. The error seems to be in the account module when it's trying to check "if (authService.isInternalAuth)" and throwing an undefined error.
4 Answer(s)
-
0
Hi,
Sorry to hear that.
Updating client-proxies might be required. Can you check if your client-proxies are updated?
https://abp.io/docs/latest/framework/ui/angular/service-proxiesOur @angularteam will help you better in this issue soon.
-
0
Hello, thanks for the reply.
Proxies and packages are updated.
For more context, this undefined error only happens after the user tries to set the password following the email link. The error page which opens seems to be a default one as well and after clicking on the "Home" button the same if check doesn't error out anymore unless trying to set the password again from the email. -
0
An update on this since the last message is that we managed to have this temporarily fixed by changing the "&__tenant=" query parameter to "&tenant=" and adapting our frontend code to use this.
Also worth mentioning that we have slightly modified flow than the abp one since our url is pointing to the frontend instead of backend so we're not sure if it's something we missed in the configuration or not.
But then again, we've had this flow for a long time and it worked fine, only after updating it stopped working.
Thanks. -
0
Hello, sorry for the delayed response. If you are still experiencing the issue, I recommend overriding the authentication guard as a temporary solution until we release an official fix:
// new-auth-flow-guard.ts import { AuthService } from '@abp/ng.core'; import { inject } from '@angular/core'; export const newAuthenticationFlowGuard = () => { const authService = inject(AuthService); if (authService?.isInternalAuth) { return true; } authService.navigateToLogin(); return false; };
Then, update your
app-routing.module.ts
as follows:import { newAuthenticationFlowGuard } from './new-auth-flow-guard'; { path: 'account', loadChildren: () => import('@volo/abp.ng.account/public').then(m => m.AccountPublicModule.forLazy()), canActivate: [newAuthenticationFlowGuard], }