1

Not quite sure if calling entity_save() from code will trigger the update event or not.

So, does it?

2

Assuming you're asking whether or not entity_save() invokes hook_entity_update(): no, it doesn't.

The controller class (or save callback function) for an entity type may well invoke it (for example node_save() does), but you can't rely on it for an entity type without checking the code first.

  • Thanks. This means I will have to use module_invoke_all('entity_update', $entity, 'entity_type') on my own – Marius Ilie Feb 27 '15 at 11:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.