Small bits of refactoring