export const handleUpdateUsername = async (id: string, username: string) => {
const { data, error } = await supabase
.from('profiles')
.update({ username: username })
.match({ id: id })
.single();
if (error) {
console.log('error', error);
return error;
} else {
console.log('data', data);
return data;
}
};
export const handleUpdateUsername = async (id: string, username: string) => {
const { data, error } = await supabase
.from('profiles')
.update({ username: username })
.match({ id: id })
.single();
if (error) {
console.log('error', error);
return error;
} else {
console.log('data', data);
return data;
}
};