Tidying up, fixing a few broken bits.