Fixed bug where the Pet result may be null