Update server injected subpath detection

This commit is contained in:
schroda
2025-09-24 23:13:29 +02:00
parent a2d7091712
commit ad3b8d4567
6 changed files with 54 additions and 97 deletions

View File

@@ -10,7 +10,7 @@ import { AppStorage } from '@/lib/storage/AppStorage.ts';
import { UserRefreshMutation } from '@/lib/graphql/generated/graphql.ts';
import { AuthManager } from '@/features/authentication/AuthManager.ts';
import { AbortableApolloMutationResponse } from '@/lib/requests/RequestManager.ts';
import { SubpathConfig } from '@/lib/utils/SubpathConfig.ts';
import { SubpathUtil } from '@/lib/utils/SubpathUtil.ts';
export abstract class BaseClient<Client, ClientConfig, Fetcher> {
protected abstract client: Client;
@@ -72,7 +72,7 @@ export abstract class BaseClient<Client, ClientConfig, Fetcher> {
const serverBaseURL = AppStorage.local.getItemParsed('serverBaseURL', defaultUrl);
// Apply subpath configuration to the base URL
return SubpathConfig.getApiBaseUrl(serverBaseURL);
return SubpathUtil.getApiBaseUrl(serverBaseURL);
}
public abstract updateConfig(config: Partial<ClientConfig>): void;