Improved helm check for avatar function