More tidying of source for modular development