public function ContentHasher::getChangelist in Tome 8
Get a list of changed content.
Return value
array An array of arrays of content names, keyed by the kind of change:
- deleted
- added
- modified
Overrides ContentHasherInterface::getChangelist
File
- modules/
tome_sync/ src/ ContentHasher.php, line 67
Class
- ContentHasher
- Hashes normalized content in the database.
Namespace
Drupal\tome_syncCode
public function getChangelist() {
$content_hashes = $this
->getContentHashes();
$source_content_hashes = $this
->getSourceContentHashes();
return [
'modified' => array_keys(array_diff(array_intersect_key($content_hashes, $source_content_hashes), $source_content_hashes)),
'added' => array_keys(array_diff_key($source_content_hashes, $content_hashes)),
'deleted' => array_keys(array_diff_key($content_hashes, $source_content_hashes)),
];
}