Merge branch 'external-baseurl' into 'main'

Fall back to external baseurl in API client

Closes #1663

See merge request soapbox-pub/soapbox!3027
This commit is contained in:
Alex Gleason 2024-05-21 16:40:04 +00:00
commit 42ee95a8fe
1 changed files with 1 additions and 1 deletions

View File

@ -103,7 +103,7 @@ export default (getState: () => RootState, authType: string = 'user'): AxiosInst
const state = getState();
const accessToken = getToken(state, authType);
const me = state.me;
const baseURL = me ? getAuthBaseURL(state, me) : '';
const baseURL = me ? getAuthBaseURL(state, me) : localStorage.getItem('soapbox:external:baseurl') ?? '';
const relayUrl = state.getIn(['instance', 'nostr', 'relay']) as string | undefined;
const pubkey = state.getIn(['instance', 'nostr', 'pubkey']) as string | undefined;