You are here

public function GDPRFieldData::includeRelatedEntities in General Data Protection Regulation 7

Whether to recurse to entities included in this property.

File

modules/gdpr_fields/src/Plugins/GDPRFieldData.php, line 192
Contains the GDPRFieldData class.

Class

GDPRFieldData
Class for storing GDPR metadata for fields.

Code

public function includeRelatedEntities() {

  // If not explicitly a GDPR field, don't recurse.
  if (!$this
    ->getSetting('gdpr_fields_enabled')) {
    return FALSE;
  }

  // If the field is an owner, don't recurse.
  if ($this
    ->getSetting('gdpr_fields_owner')) {
    return FALSE;
  }

  // Don't follow if we've been explicitly set not to.
  if ($this
    ->getSetting('gdpr_fields_no_follow')) {
    return FALSE;
  }
  return TRUE;
}