aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/core/routing/server-config-resolver.service.ts
blob: 0ce2023a0b9396013e80e53d7cc6719ff02af0e4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
import { Injectable } from '@angular/core'
import { Resolve } from '@angular/router'
import { ServerService } from '../server'
import { ServerConfig } from '@shared/models'

@Injectable()
export class ServerConfigResolver implements Resolve<ServerConfig> {
  constructor (private server: ServerService) {}

  resolve () {
    return this.server.getConfig()
  }
}