fix bug with pass id to update method