maj pricing, configuration du prisma
This commit is contained in:
@@ -7,7 +7,7 @@ import { useEffect } from 'react';
|
||||
|
||||
export default function ProfilePage() {
|
||||
const router = useRouter();
|
||||
const { user, loading } = useAuthContext();
|
||||
const { user, loading, updateProfile } = useAuthContext();
|
||||
|
||||
useEffect(() => {
|
||||
if (!loading && !user) {
|
||||
@@ -20,7 +20,13 @@ export default function ProfilePage() {
|
||||
return (
|
||||
<UserProfileSettings
|
||||
user={user}
|
||||
onUpdate={(updates) => console.log('Profile update:', updates)}
|
||||
onUpdate={async (updates) => {
|
||||
try {
|
||||
await updateProfile(updates);
|
||||
} catch (err) {
|
||||
// Handled inside updateProfile (console.error)
|
||||
}
|
||||
}}
|
||||
onBack={() => router.push('/dashboard')}
|
||||
/>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user