Code cleanup...mostly.