aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/app.component.ts
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/app.component.ts')
-rw-r--r--client/src/app/app.component.ts3
1 files changed, 2 insertions, 1 deletions
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
4import { AuthService, RedirectService, ServerService, ThemeService } from '@app/core' 4import { AuthService, RedirectService, ServerService, ThemeService } from '@app/core'
5import { is18nPath } from '../../../shared/models/i18n' 5import { is18nPath } from '../../../shared/models/i18n'
6import { ScreenService } from '@app/shared/misc/screen.service' 6import { ScreenService } from '@app/shared/misc/screen.service'
7import { debounceTime, filter, map, pairwise, skip, switchMap } from 'rxjs/operators' 7import { debounceTime, filter, first, map, pairwise, skip, switchMap } from 'rxjs/operators'
8import { Hotkey, HotkeysService } from 'angular2-hotkeys' 8import { Hotkey, HotkeysService } from 'angular2-hotkeys'
9import { I18n } from '@ngx-translate/i18n-polyfill' 9import { I18n } from '@ngx-translate/i18n-polyfill'
10import { fromEvent } from 'rxjs' 10import { fromEvent } from 'rxjs'
@@ -234,6 +234,7 @@ export class AppComponent implements OnInit {
234 private async openModalsIfNeeded () { 234 private async openModalsIfNeeded () {
235 this.serverService.configLoaded 235 this.serverService.configLoaded
236 .pipe( 236 .pipe(
237 first(),
237 switchMap(() => this.authService.userInformationLoaded), 238 switchMap(() => this.authService.userInformationLoaded),
238 map(() => this.authService.getUser()), 239 map(() => this.authService.getUser()),
239 filter(user => user.role === UserRole.ADMINISTRATOR) 240 filter(user => user.role === UserRole.ADMINISTRATOR)