1
0
Fork 0

Fix welcome modal when saving config

This commit is contained in:
Chocobozzz 2019-11-27 10:29:05 +01:00
parent 918058dea3
commit 414131338d
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
1 changed files with 2 additions and 1 deletions

View File

@ -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)