Refactor context reducer to TypeScript (#34506)
This commit is contained in:
parent
bd9223f0b9
commit
17d8e2b6e3
13 changed files with 308 additions and 234 deletions
|
@ -39,9 +39,9 @@ export const NotificationMention: React.FC<{
|
|||
unread: boolean;
|
||||
}> = ({ notification, unread }) => {
|
||||
const [isDirect, isReply] = useAppSelector((state) => {
|
||||
const status = state.statuses.get(notification.statusId) as
|
||||
| Status
|
||||
| undefined;
|
||||
const status = notification.statusId
|
||||
? (state.statuses.get(notification.statusId) as Status | undefined)
|
||||
: undefined;
|
||||
|
||||
if (!status) return [false, false] as const;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue