remove more unused code
make init code more readable