Improve compatibility (#7214)

* refactor content

* refactor core

* refactor rest

* fix lint

* fix

* lint

* lint

* fix

* fix

* fix
This commit is contained in:
Eugenio Romano
2021-08-16 11:42:29 +02:00
committed by GitHub
parent 8c8e388fa0
commit a25923d1f2
62 changed files with 595 additions and 235 deletions

View File

@@ -48,7 +48,11 @@ export class AuthenticationService {
*/
onLogout: ReplaySubject<any> = new ReplaySubject<any>(1);
private profileApi: UserProfileApi;
_profileApi: UserProfileApi;
get profileApi(): UserProfileApi {
this._profileApi = this._profileApi ?? new UserProfileApi(this.alfrescoApi.getInstance());
return this._profileApi;
}
constructor(
private appConfig: AppConfigService,
@@ -58,7 +62,6 @@ export class AuthenticationService {
private logService: LogService) {
this.alfrescoApi.alfrescoApiInitialized.subscribe(() => {
this.alfrescoApi.getInstance().reply('logged-in', () => {
this.profileApi = new UserProfileApi(alfrescoApi.getInstance());
this.onLogin.next();
});
});