Refactor to pass pep8