Fixed error when quitting debug menu