Problem/Motivation

When you edit a node and make changes to any fields that are sent in the article to Apple News, those changes are not included until you save again.

The reason for this is that in applenews_op, the call to applenews_entity_export passes along the entity_type and entity_id, and not the entity object which has the latest information. applenew_entity_export then calls entity_load_single, which will fetch the entity without the changes. The exporter then works with this old copy of the entity and fails to push the changes to Apple News.

Proposed resolution

Change the function signature of applenews_entity_export to accept an entity object as a paramater and shift responsibility to the caller to load the entity object if need be.

Remaining tasks

I can haz code?

User interface changes

None.

API changes

Changing the signature of applenews_entity_export

Data model changes

None.

CommentFileSizeAuthor
#2 2846096-node_update_bug-2.patch2.49 KBm4olivei

Comments

m4olivei created an issue. See original summary.

m4olivei’s picture

Status: Active » Needs review
StatusFileSize
new2.49 KB

Patch attached.

  • m4olivei committed 3477278 on 7.x-2.x
    Issue #2846096 fix a bug on node update where the latest version of the...
m4olivei’s picture

Status: Needs review » Fixed

Merged to 7.x-2.x

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.