Updated user avatar upload logic