Lines refactoring