yet more refactoring

not much to say here.