Core/Pets: Fixed crashes introduced in 1496e4df842db07ec5b2474b05d8279f0e4a907b