From 414131338df3e94982a71179ee15ebc9b3dedb06 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 27 Nov 2019 10:29:05 +0100 Subject: Fix welcome modal when saving config --- client/src/app/app.component.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'client') diff --git a/client/src/app/app.component.ts b/client/src/app/app.component.ts index 1724bbd1a..f1658ca1b 100644 --- a/client/src/app/app.component.ts +++ b/client/src/app/app.component.ts @@ -4,7 +4,7 @@ import { Event, GuardsCheckStart, NavigationEnd, Router, Scroll } from '@angular import { AuthService, RedirectService, ServerService, ThemeService } from '@app/core' import { is18nPath } from '../../../shared/models/i18n' import { ScreenService } from '@app/shared/misc/screen.service' -import { debounceTime, filter, map, pairwise, skip, switchMap } from 'rxjs/operators' +import { debounceTime, filter, first, map, pairwise, skip, switchMap } from 'rxjs/operators' import { Hotkey, HotkeysService } from 'angular2-hotkeys' import { I18n } from '@ngx-translate/i18n-polyfill' import { fromEvent } from 'rxjs' @@ -234,6 +234,7 @@ export class AppComponent implements OnInit { private async openModalsIfNeeded () { this.serverService.configLoaded .pipe( + first(), switchMap(() => this.authService.userInformationLoaded), map(() => this.authService.getUser()), filter(user => user.role === UserRole.ADMINISTRATOR) -- cgit v1.2.3