Fixed CRUD update function to work on subobjects