More small refactors