File tree 1 file changed +10
-1
lines changed
dashboard/new-dashboard/src/configurators
1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,8 @@ import { dbTypeStore } from "../shared/dbTypes"
5
5
import { injectOrError , serverUrlObservableKey } from "../shared/injectionKeys"
6
6
7
7
export class ServerWithCompressConfigurator implements ServerConfigurator {
8
- static readonly DEFAULT_SERVER_URL = "https://ij-perf.labs.jb.gg"
8
+ static readonly DEFAULT_SERVER_URL = ServerWithCompressConfigurator . determineServerUrl ( )
9
+ static readonly INTRANET_SERVER_URL = "https://ij-perf-api.labs.jb.gg"
9
10
10
11
private readonly observable : Observable < null >
11
12
private _serverUrl : string = ServerWithCompressConfigurator . DEFAULT_SERVER_URL
@@ -26,6 +27,14 @@ export class ServerWithCompressConfigurator implements ServerConfigurator {
26
27
)
27
28
}
28
29
30
+ private static determineServerUrl ( ) : string {
31
+ if ( window . location . hostname === "ij-perf-api.labs.jb.gg" ) {
32
+ return ServerWithCompressConfigurator . INTRANET_SERVER_URL
33
+ } else {
34
+ return "https://ij-perf.labs.jb.gg"
35
+ }
36
+ }
37
+
29
38
get serverUrl ( ) : string {
30
39
return this . _serverUrl
31
40
}
You can’t perform that action at this time.
0 commit comments