protected function getEntitySchema(ContentEntityTypeInterface $entity_type, $reset = FALSE) {
$schema = parent::getEntitySchema($entity_type, $reset);
- $schema['node_field_data']['indexes'] += [
- 'node__frontpage' => ['promote', 'status', 'sticky', 'created'],
- 'node__title_type' => ['title', ['type', 4]],
- ];
+ if ($data_table = $this->storage->getDataTable()) {
+ $schema[$data_table]['indexes'] += [
+ 'node__frontpage' => ['promote', 'status', 'sticky', 'created'],
+ 'node__title_type' => ['title', ['type', 4]],
+ ];
+ }
return $schema;
}