mass cleaning and fixes