Changed order of initializing objects