mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-04-11 17:16:20 +00:00
Pass HTTP credentials through to the API server when appropriate CORS headers are set
This commit is contained in:
committed by
Alejandro Celaya
parent
c1bbeeb6ac
commit
d1d6a6b373
@@ -23,7 +23,7 @@ export const buildShlinkApiClient = (httpClient: HttpClient) => (getStateOrSelec
|
||||
: getStateOrSelectedServer;
|
||||
const serverKey = `${apiKey}_${baseUrl}`;
|
||||
|
||||
const apiClient = apiClients[serverKey] ?? new ShlinkApiClient(httpClient, { apiKey, baseUrl });
|
||||
const apiClient = apiClients[serverKey] ?? new ShlinkApiClient(httpClient, { apiKey, baseUrl }, { credentials: 'include' });
|
||||
apiClients[serverKey] = apiClient;
|
||||
|
||||
return apiClient;
|
||||
|
||||
Reference in New Issue
Block a user