diff options
Diffstat (limited to 'frontend/src/api/Api.ts')
| -rw-r--r-- | frontend/src/api/Api.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/frontend/src/api/Api.ts b/frontend/src/api/Api.ts index df787e3..19ece86 100644 --- a/frontend/src/api/Api.ts +++ b/frontend/src/api/Api.ts | |||
| @@ -49,7 +49,9 @@ export const API = { | |||
| 49 | delete_map_summary: (token: string, map_id: string, route_id: number) => delete_map_summary(token, map_id, route_id), | 49 | delete_map_summary: (token: string, map_id: string, route_id: number) => delete_map_summary(token, map_id, route_id), |
| 50 | }; | 50 | }; |
| 51 | 51 | ||
| 52 | const BASE_API_URL: string = "https://lp.portal2.sr/api/v1/" | 52 | const BASE_API_URL: string = import.meta.env.DEV |
| 53 | ? "https://lp.portal2.sr/api/v1/" | ||
| 54 | : "/api/v1/" | ||
| 53 | 55 | ||
| 54 | export function url(path: string): string { | 56 | export function url(path: string): string { |
| 55 | return BASE_API_URL + path; | 57 | return BASE_API_URL + path; |