Update fetchUserProfile to use demo storage

cgen-2d2c03722ede4bc59d50bb88039f8228
This commit is contained in:
Builder.io 2025-08-06 00:25:39 +00:00
parent a2b14d27bc
commit 132c55fb72

View file

@ -86,25 +86,10 @@ export const AuthProvider: React.FC<{ children: React.ReactNode }> = ({ children
const fetchUserProfile = async (userId: string) => {
if (!isSupabaseConfigured) {
// Set demo profile
setProfile({
id: userId,
username: 'demo-user',
full_name: 'Demo User',
user_type: 'game_developer',
experience_level: 'intermediate',
total_xp: 150,
level: 3,
created_at: new Date().toISOString(),
updated_at: new Date().toISOString(),
avatar_url: null,
bio: 'Demo user profile',
location: null,
website_url: null,
github_url: null,
twitter_url: null,
linkedin_url: null,
});
// Initialize demo data and get profile
DemoStorageService.initializeDemoData();
const demoProfile = DemoStorageService.getUserProfile();
setProfile(demoProfile);
return;
}