Minor coding refactors