fix: handle deleted funds in trade and profile displays
Build Images and Deploy / Update-PROD-Stack (push) Successful in 1m20s

This commit is contained in:
2026-03-20 20:19:49 -04:00
parent ef01ea9a3a
commit 5020f38090
2 changed files with 17 additions and 9 deletions
+6 -2
View File
@@ -97,9 +97,13 @@ export default async function TradeHistoryPage({ searchParams }: PageProps) {
: 'Account opened'} : 'Account opened'}
</span> </span>
) : isFundTrade ? ( ) : isFundTrade ? (
<Link href={`/fund/${t.fund!.slug}`} className="hover:text-indigo-300"> t.fund ? (
{t.fund!.name} <Link href={`/fund/${t.fund.slug}`} className="hover:text-indigo-300">
{t.fund.name}
</Link> </Link>
) : (
<span className="text-slate-500">Deleted Fund</span>
)
) : ( ) : (
<Link <Link
href={`/hashtag/${t.hashtag!.tag}`} href={`/hashtag/${t.hashtag!.tag}`}
+6 -2
View File
@@ -331,12 +331,16 @@ export default async function ProfilePage({ params }: Props) {
: 'Account opened'} : 'Account opened'}
</span> </span>
) : isFundTrade ? ( ) : isFundTrade ? (
t.fund ? (
<Link <Link
href={`/fund/${t.fund!.slug}`} href={`/fund/${t.fund.slug}`}
className="text-indigo-300 hover:text-indigo-200 font-medium truncate flex-1 min-w-0" className="text-indigo-300 hover:text-indigo-200 font-medium truncate flex-1 min-w-0"
> >
{t.fund!.name} {t.fund.name}
</Link> </Link>
) : (
<span className="text-slate-500 font-medium flex-1 min-w-0">Deleted Fund</span>
)
) : ( ) : (
<Link <Link
href={`/hashtag/${t.hashtag!.tag}`} href={`/hashtag/${t.hashtag!.tag}`}