refactor init (efficiency)