Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 295826

ChangedItem will not detect a change if another field item changes its value in field::preSave

$
0
0

Problem/Motivation

At the moment the ChangedItem will check all fields for changes in its preSave function, but if there are other fields defined which are updating the field value in the preSave function then the ChangedItem::preSave is not going to detect this change, because it will be one of the first that is called.

Proposed resolution

Make sure ChangedItem::preSave is called as the last one of all other FieldItems::preSave.. This could be done by ensuring that EntityFieldManager::getFieldDefinitions will return an array of field definitions, where the changed field definition is at the end.

Remaining tasks

none

User interface changes

none

API changes

none

Data model changes

none


Viewing all articles
Browse latest Browse all 295826

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>