Refactoring, pep8 and objects.count()