Remove init function

put the content of init in the constructor