Fix swap when lines isn't possible