Social Sign-on - Google - scope out image?

Hello, is there a way to scope OUT of google authentication the gmail profile image? In other words, I dont want to port over the gmail avatar into my user instance. How could I disactivate such? thanks!
1 Reply
srd
srd5mo ago
databaseHooks: {
user: {
create: {
before: async (user) => {
const { image, ...userWithoutImage } = user;
return {
data: userWithoutImage
};
},
},
},
},
databaseHooks: {
user: {
create: {
before: async (user) => {
const { image, ...userWithoutImage } = user;
return {
data: userWithoutImage
};
},
},
},
},
i have done this to disable image all together, but this seems to not work with social providers. social providers just overwrite it
return {
data: {
...user,
image: null
}
};
return {
data: {
...user,
image: null
}
};
this removes the image, but you still have to have the image column in the db, depending if you dont want images with your app or just not port over googles images

Did you find this page helpful?