Co-Authors-Plus icon indicating copy to clipboard operation
Co-Authors-Plus copied to clipboard

Show alert if guest author profile has thumbnail and is missing an email address

Open danielbachhuber opened this issue 12 years ago • 4 comments

If a guest author profile has a thumbnail, but is missing an email address, we should show a warning / require that an email address be entered.

Otherwise, the user will experience unexpected results on the frontend.

danielbachhuber avatar Feb 18 '13 08:02 danielbachhuber

... or we could generate a fake email address for the guest author so our filter hack works...

danielbachhuber avatar Feb 11 '14 00:02 danielbachhuber

I am marking this as a bug because one of the unexpected front end results is trying to use a blank gravatar instead of showing the featured image/thumbnail.

IMO: We shouldn't require an email address we should just default to using the featured image. I'm not sure what the email address is used for though. If it's important than we should show an alert like was originally suggested.

If we are going to require an email I would suggest going with the filter method as it's better for the users than an alert.

cc @joshbetz

BrookeDot avatar Oct 14 '14 20:10 BrookeDot

I'm not sure what the email address is used for though.

Because get_avatar() also supports supplying a $user_id. However, should you have a user with ID 5 and a guest author with ID 5 (because guest authors are stored as posts), then the guest author would collide with the user.

danielbachhuber avatar Oct 14 '14 20:10 danielbachhuber

is this still valid? I encountered this issue today when I couldn't use get_avatar() with ID instead of user_email for guest authors without email. just opened a new thread for that, please have a look here: https://github.com/Automattic/Co-Authors-Plus/issues/616

ituk avatar Nov 03 '18 21:11 ituk