Issue #3206932: Rename targetEntityType constant in d6_view_mode migration to...
1 open thread
Merge request reports
Activity
71 71 public function calculateDependencies() { 72 72 $this->dependencies = parent::calculateDependencies(); 73 73 if (isset($this->configuration['constants']['targetEntityType'])) { 74 @trigger_error('The constant targetEntityType is deprecated in drupal:9.2.0 and is removed in drupal:10.0.0. Use entity_type instead. See https://www.drupal.org/node/3208135', E_USER_DEPRECATED); I think for proper BC here this method should become:
if (isset($this->configuration['constants']['targetEntityType'])) { @trigger_error('The constant targetEntityType is deprecated in drupal:9.2.0 and is removed in drupal:10.0.0. Use entity_type instead. See https://www.drupal.org/node/3208135', E_USER_DEPRECATED); $this->configuration['constants']['entity_type'] = $this->configuration['constants']['targetEntityType']; } $this->dependencies = parent::calculateDependencies(); return $this->dependencies;
That way code can rely on entity_type being set and everything working off of that as it will once we remove
if (isset($this->configuration['constants']['targetEntityType'])) { @trigger_error('The constant targetEntityType is deprecated in drupal:9.2.0 and is removed in drupal:10.0.0. Use entity_type instead. See https://www.drupal.org/node/3208135', E_USER_DEPRECATED); $this->configuration['constants']['entity_type'] = $this->configuration['constants']['targetEntityType']; }
Please register or sign in to reply