A slight refactor