Removed 200 lines by refactoring sources of code smell.