strangerstudios / basic-user-avatars

Add an avatar upload field on frontend pages and on the Edit Profile screen so users and admins can manage custom profile pictures without Gravatar.
https://wordpress.org/plugins/basic-user-avatars/
39 stars 34 forks source link

Fix PHP Notice with $image_sized #11

Closed jjeaton closed 9 years ago

jjeaton commented 9 years ago

Sets $image_sized and checks whether it’s empty in addition to checking for WP_Error. Fixes a notice on the user pages if a user has managed to upload an invalid image.

Right now it will fallback to the full size, but if the full image is invalid anyways, it will still show a broken image but won’t throw a notice. It could be changed to fallback to the default avatar instead.