mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-12-29 15:13:11 +01:00
[Glitch] Fix relationship not being fetched to evaluate whether to show a quote post
Port 811c1eaf7e to glitch-soc
Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
@@ -12,6 +12,7 @@ import type { Status } from 'flavours/glitch/models/status';
|
||||
import type { RootState } from 'flavours/glitch/store';
|
||||
import { useAppDispatch, useAppSelector } from 'flavours/glitch/store';
|
||||
|
||||
import { fetchRelationships } from '../actions/accounts';
|
||||
import { revealAccount } from '../actions/accounts_typed';
|
||||
import { fetchStatus } from '../actions/statuses';
|
||||
import { makeGetStatusWithExtraInfo } from '../selectors';
|
||||
@@ -148,6 +149,10 @@ export const QuotedStatus: React.FC<QuotedStatusProps> = ({
|
||||
}
|
||||
}, [shouldFetchQuote, quotedStatusId, parentQuotePostId, dispatch]);
|
||||
|
||||
useEffect(() => {
|
||||
if (accountId && hiddenAccount) dispatch(fetchRelationships([accountId]));
|
||||
}, [accountId, hiddenAccount, dispatch]);
|
||||
|
||||
const isFilteredAndHidden = loadingState === 'filtered';
|
||||
|
||||
let quoteError: React.ReactNode = null;
|
||||
|
||||
Reference in New Issue
Block a user