Some work and fixes