update init logic