code climate refactoring