Refactor: Initialization code now all in one place