From 7b1fd9b63a57c68fb613d480afb402e8441de5fe Mon Sep 17 00:00:00 2001 From: "Builder.io" Date: Wed, 6 Aug 2025 03:21:07 +0000 Subject: [PATCH] Remove duplicate user declaration (old mock data) cgen-6a05577b5c9b4bfcb854912093b0200d --- client/pages/Dashboard.tsx | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/client/pages/Dashboard.tsx b/client/pages/Dashboard.tsx index ddeba01c..704faa6b 100644 --- a/client/pages/Dashboard.tsx +++ b/client/pages/Dashboard.tsx @@ -121,18 +121,16 @@ export default function Dashboard() { } }; - // Mock user data - const user = { - name: "Alex Thompson", - role: "Game Developer", - level: 15, - xp: 2450, - nextLevelXp: 3000, - avatar: - "https://images.unsplash.com/photo-1472099645785-5658abf4ff4e?w=100&h=100&fit=crop&crop=face", - joinDate: "March 2024", - streak: 12, - }; + // Return early if not authenticated + if (authLoading || !user || !profile) { + return ( + + ); + } const stats = [ {