function commerce_entity_is_unchanged in Commerce Core 7
Determines whether or not the given entity object was loaded directly from the database to represent the unchanged version of the entity.
Parameters
string $entity_type: The type of $entity; for example, 'commerce_order'.
object $entity: The entity to check.
Return value
bool TRUE if the entity is "unchanged", FALSE otherwise.
1 call to commerce_entity_is_unchanged()
- commerce_cart_commerce_order_load in modules/
cart/ commerce_cart.module - Implements hook_commerce_order_load().
File
- ./
commerce.module, line 1378 - Defines features and functions common to the Commerce modules.
Code
function commerce_entity_is_unchanged($entity_type, $entity) {
return entity_get_controller($entity_type)
->isUnchanged($entity);
}