Refactoring based on suggestions