Update updateProfile to use demo storage

cgen-92bfa12f800f4a8791b96c1dc0fac289
This commit is contained in:
Builder.io 2025-08-06 00:25:47 +00:00
parent 132c55fb72
commit af01ad03e7

View file

@ -210,12 +210,13 @@ export const AuthProvider: React.FC<{ children: React.ReactNode }> = ({ children
if (!user) throw new Error('No user logged in');
if (!isSupabaseConfigured) {
aethexToast.info({
title: 'Demo Mode',
description: 'Profile updates are simulated in demo mode'
// Use demo storage
const updatedProfile = DemoStorageService.updateUserProfile(updates);
setProfile(updatedProfile);
aethexToast.success({
title: 'Profile updated',
description: 'Your profile has been updated successfully'
});
// Simulate profile update
setProfile(prev => prev ? { ...prev, ...updates } : null);
return;
}