Remove type assertion when not needed

Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
marcin mikołajczak
2023-10-22 00:20:41 +02:00
parent ba5e018e3c
commit b1daf3ef13
8 changed files with 28 additions and 31 deletions

View File

@ -14,7 +14,7 @@ import { buildStatus } from '../util/pending-status-builder';
import PollPreview from './poll-preview';
import type { Account as AccountEntity, Status as StatusEntity } from 'soapbox/types/entities';
import type { Status as StatusEntity } from 'soapbox/types/entities';
const shouldHaveCard = (pendingStatus: StatusEntity) => {
return Boolean(pendingStatus.content.match(/https?:\/\/\S*/));
@ -54,7 +54,7 @@ const PendingStatus: React.FC<IPendingStatus> = ({ idempotencyKey, className, mu
if (!status) return null;
if (!status.account) return null;
const account = status.account as AccountEntity;
const account = status.account;
return (
<div className={clsx('opacity-50', className)}>