Skip to content

Commit e9c0f3d

Browse files
committed
refactor: fix theme icon duplication, simplify error handling, and clean up unused imports
1 parent 907cbd8 commit e9c0f3d

3 files changed

Lines changed: 2 additions & 8 deletions

File tree

app/(root)/dashboard/[username]/page.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ export default async function DashboardPage({
7575
if (fallbackProfile.type === 'Organization') {
7676
redirect(`/dashboard/org/${username}`);
7777
}
78-
} catch (fallbackError) {
78+
} catch {
7979
// If it's truly neither a user nor an org, show 404
8080
return notFound();
8181
}

app/api/streak/route.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,7 @@
33
import { NextResponse } from 'next/server';
44
import { fetchGitHubContributions, getOrgDashboardData } from '@/lib/github';
55
import { calculateStreak, calculateMonthlyStats } from '@/lib/calculate';
6-
import {
7-
generateNotFoundSVG,
8-
generateSVG,
9-
generateMonthlySVG,
10-
escapeXML,
11-
} from '@/lib/svg/generator';
6+
import { generateNotFoundSVG, generateSVG, generateMonthlySVG } from '@/lib/svg/generator';
127
import { getSecondsUntilUTCMidnight, getSecondsUntilMidnightInTimezone } from '@/utils/time';
138
import type { BadgeParams } from '@/types';
149
import { themes } from '@/lib/svg/themes';

app/customize/components/ThemeQuickPresets.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -508,7 +508,6 @@ const ICON_MAP: Record<string, (c: IC) => ReactElement> = {
508508
nord: (c) => <IconNord {...c} />,
509509
synthwave: (c) => <IconSynthwave {...c} />,
510510
gruvbox: (c) => <IconGruvbox {...c} />,
511-
aurora_cyberpunk: (c) => <IconDark {...c} />,
512511
highcontrast: (c) => <IconHighcontrast {...c} />,
513512
aurora_cyberpunk: (c) => <IconAuroraCyberpunk {...c} />,
514513
catppuccin_latte: (c) => <IconCatppuccinLatte {...c} />,

0 commit comments

Comments
 (0)