fix perfhud from throwing undefined errors