diff --git a/includes/commerce_product.inline_entity_form.inc b/includes/commerce_product.inline_entity_form.inc index 63b52db..a497dc0 100644 --- a/includes/commerce_product.inline_entity_form.inc +++ b/includes/commerce_product.inline_entity_form.inc @@ -390,7 +390,7 @@ class CommerceProductInlineEntityFormController extends EntityInlineEntityFormCo * referenced from a line item, or for some other reason), deletes the rest. */ public function delete($ids, $context) { - $products = entity_load('commerce_product', $ids); + $products = entity_load_multiple('commerce_product', $ids); foreach ((array) $products as $product_id => $product) { if (!commerce_product_can_delete($product)) { $product->status = FALSE; diff --git a/includes/taxonomy_term.inline_entity_form.inc b/includes/taxonomy_term.inline_entity_form.inc index 14be8e1..01e0171 100644 --- a/includes/taxonomy_term.inline_entity_form.inc +++ b/includes/taxonomy_term.inline_entity_form.inc @@ -70,12 +70,6 @@ class TaxonomyTermInlineEntityFormController extends EntityInlineEntityFormContr $entity = $entity_form['#entity']; - // Set the vocabulary ID. - $vocabularies = taxonomy_vocabulary_get_names(); - if (isset($vocabularies[$entity->vocabulary_machine_name])) { - $entity->vid = $vocabularies[$entity->vocabulary_machine_name]->vid; - } - // Separate the description and format. $entity->format = $entity->description['format']; $entity->description = $entity->description['value']; diff --git a/inline_entity_form.module b/inline_entity_form.module index 7e5d091..32ea4a4 100644 --- a/inline_entity_form.module +++ b/inline_entity_form.module @@ -454,7 +454,7 @@ function inline_entity_form_field_widget_form(&$form, &$form_state, $field, $ins } $delta = 0; - foreach (entity_load($settings['entity_type'], $entity_ids) as $entity) { + foreach (entity_load_multiple($settings['entity_type'], $entity_ids) as $entity) { $form_state['inline_entity_form'][$ief_id]['entities'][$delta] = array( 'entity' => $entity, 'weight' => $delta, @@ -1135,7 +1135,7 @@ function inline_entity_form_reference_form_validate(&$reference_form, &$form_sta $labels = $controller->labels(); $form_values = backdrop_array_get_nested_value($form_state['values'], $reference_form['#parents']); - $attach_entity = entity_load_single($entity_type, $form_values['entity_id']); + $attach_entity = entity_load($entity_type, $form_values['entity_id']); // Check to see if entity is already referenced by current IEF widget if (!empty($attach_entity)) { @@ -1166,7 +1166,7 @@ function inline_entity_form_reference_form_submit($reference_form, &$form_state) $entity_type = $reference_form['#entity_type']; $form_values = backdrop_array_get_nested_value($form_state['values'], $reference_form['#parents']); - $attach_entity = entity_load_single($entity_type, $form_values['entity_id']); + $attach_entity = entity_load($entity_type, $form_values['entity_id']); // Determine the correct weight of the new element. $weight = 0;