moved init code to setup