Fixed the dead battery check