Prevent "invalid access token" error when opening Mastodon while logged out (#37256)

This commit is contained in:
diondiondion 2025-12-15 16:24:03 +01:00 committed by GitHub
parent 9d18df4f8a
commit 807e1254e6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -62,7 +62,8 @@ export const checkAnnualReport = createAppThunk(
`${annualReportSlice.name}/checkAnnualReport`,
(_arg: unknown, { dispatch, getState }) => {
const year = selectWrapstodonYear(getState());
if (!year) {
const me = getState().meta.get('me') as string;
if (!year || !me) {
return;
}
void dispatch(fetchReportState());