protected function getUnselectedFields() {
    $profile_fields = $this->fieldStorage->loadByProperties(['entity_type' => 'profile', 'bundle' => 'profile']);
    $settings = $this->configFactory->get('social_profile_fields.settings');
    $empty = [];

    /** @var \Drupal\field\Entity\FieldConfig $value */
    foreach ($profile_fields as $key => $value) {
      $sval = $settings->get(str_replace('.', '_', $key));

      if (isset($sval) && $sval == FALSE) {
        $empty[] = $value->getName();
      }
    }
    return $empty;
  }
protected function getUnselectedFields() {
    $profile_fields = $this->fieldStorage->loadByProperties(['entity_type' => 'profile', 'bundle' => 'profile']);
    $settings = $this->configFactory->get('social_profile_fields.settings');
    $empty = [];

    /** @var \Drupal\field\Entity\FieldConfig $value */
    foreach ($profile_fields as $key => $value) {
      $sval = $settings->get(str_replace('.', '_', $key));

      if (isset($sval) && $sval == FALSE) {
        $empty[] = $value->getName();
      }
    }
    return $empty;
  }
protected function getUnselectedFields ( ) { $ profile_fields = $ this -> fieldStorage -> loadByProperties ( [ 'entity_type' => 'profile' , 'bundle' => 'profile' ] ) ; $ settings = $ this -> configFactory -> get ( 'social_profile_fields.settings' ) ; $ empty = [ ] ; /** @var \Drupal\field\Entity\FieldConfig $value */ foreach ( $ profile_fields as $ key => $ value ) { $ sval = $ settings -> get ( str_replace ( '.' , '_' , $ key ) ) ; if ( isset ( $ sval ) && $ sval == FALSE ) { $ empty [ ] = $ value -> getName ( ) ; } } return $ empty ; }
Function that return an array of field names.

@return array
An array of field names.
Function that return an array of field names .