Added better error message for avatar upload fail