Refactory part 2