Problem/Motivation
When trying to enable the
log module β
which has this module as a requirement I got error:
PHP Fatal error: Uncaught ArgumentCountError: Too few arguments to function Drupal\views\EntityViewsData::mapSingleFieldViewsData(), 7 passed in /var/www/html/docroot/modules/contrib/entity/src/EntityViewsData.php on line 185 and exactly 8 expected in /var/www/html/docroot/core/modules/views/src/EntityViewsData.php:484
Stack trace:
#0 /var/www/html/docroot/modules/contrib/entity/src/EntityViewsData.php(185): Drupal\views\EntityViewsData->mapSingleFieldViewsData('log', 'uuid', 'uuid', 'value', 'varchar_ascii', true, Object(Drupal\Core\Field\BaseFieldDefinition))
Looking at core/modules/views/src/EntityViewsData.php I can see:
protected function mapSingleFieldViewsData($table, $field_name, $field_type, $column_name, $column_type, $first, FieldDefinitionInterface $field_definition, array &$data) {
And in modules/contrib/entity/src/EntityViewsData.php:185 I can see:
$table_data[$schema_field_name] = $this->mapSingleFieldViewsData($table, $field_name, $field_definition_type, $field_column_name, $field_schema['columns'][$field_column_name]['type'], $first, $field_definition);
This this needs to be updated to pass the $data argument with a reference to all the views data.
Steps to reproduce
drush en log