A little refactoring before I will start to develop test cases