corrected in bug in shutdown