fix bug for object init