lots of small adjustments to polish it up