027-0020 Default Avatar In Profile_view_user.php
I have found this bug after an user told me that when she watch the list of users who viewed her profile there appeared an user without name and just the "member" avatar. It was a guest, of course, but IP was displaying the wrong default avatar. This is because the user_id used to retrieve the default avatar is the current user id instead the viewer user id. Here is how to fix it:
- #
- #-----[ OPEN ]------------------------------------------
- #
-
- profile_view_users.php
-
- #
- #-----[ FIND ]------------------------------------------
- #
-
- $viewer_avatar = user_get_avatar($row['user_id'], $row['user_avatar'], $row['user_avatar_type'], $row['user_allowavatar']);
-
- #
- #-----[ REPLACE WITH ]------------------------------------------
- #
-
- $viewer_avatar = user_get_avatar($row['viewer_id'], $row['user_avatar'], $row['user_avatar_type'], $row['user_allowavatar']);
-