Skip to content

Commit 822c96d

Browse files
committed
fix typescript error
1 parent 36f9c27 commit 822c96d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

app/profile/[login]/repositories/components/repository-card.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ import type { Route } from 'next';
44
import Link from 'next/link';
55
import type { FC, ReactNode } from 'react';
66

7-
import { Badge } from '@/components/ui/badge';
8-
import { cn } from '@/lib/utils';
9-
import type { Repository } from '@/types/generated/graphql';
107
import { ProfileCard, ProfileCardContent, ProfileCardHeader } from '../../components/profile-card';
118
import { RepositoryDetail } from './repository-detail';
129
import { RepositoryLanguages } from './repository-languages';
1310
import { RepositoryTopLanguage } from './repository-top-language';
11+
import { Badge } from '@/components/ui/badge';
12+
import { cn } from '@/lib/utils';
13+
import type { Repository } from '@/types/generated/graphql';
1414

1515
type RepositoryCardProps = {
1616
repository?: Repository | null;
@@ -66,7 +66,7 @@ export const RepositoryCard: FC<RepositoryCardProps> = ({
6666
<div className="flex gap-4">
6767
{type === 'contribution' && <RepositoryTopLanguage languages={repository.languages} />}
6868
<RepositoryDetail Icon={Star} value={stargazerCount} />
69-
<RepositoryDetail Icon={Split} value={forkCount} />
69+
<RepositoryDetail Icon={Split} value={forkCount ?? 0} />
7070
{!!releasesCount && <RepositoryDetail Icon={Package} value={releasesCount} />}
7171
</div>
7272

0 commit comments

Comments
 (0)