fix create and update