When a node is created by UUID services UPDATE call, the uid property is not set properly.
The proposed solution (patch to follow) introduces a 'uuid_services_update_alter' hook to allow modules to add data to the entity being saved, and implements this on behalf of the node module.
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | uuid-2043273-set-uid.patch | 1.59 KB | skwashd |
Comments
Comment #1
wodenx commentedPatch
Comment #2
aoturoa commentedThis is correctly handled in the standard _node_resource_create() where the 'name' and 'language' are added inside the function. Now that uuid_service module uses _node_resource_update() instead, we can also add the missing values using the standard hook_entity_presave() function:
Comment #3
skwashd commentedI agree with aoturoa's suggestion.
Comment #4
recidive commentedChanged to use
hook_entity_presave().Comment #6
skwashd commentedThanks for that patch. I've merged it. Closing
Comment #7
skwashd commentedI realised after committing the change, that this logic belongs in
node_entity_uuid_presave().Comment #8
skwashd commentedComment #9
skwashd commentedThe attached patch resolves the problem.
Comment #10
recidive commentedComment #11
skwashd commentedThanks for the review. Merging.
Comment #13
skwashd commented