FlaggingStorageSchema.php in Flag 8.4
File
src/Entity/Storage/FlaggingStorageSchema.php
View source
<?php
namespace Drupal\flag\Entity\Storage;
use Drupal\Core\Entity\ContentEntityTypeInterface;
use Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema;
class FlaggingStorageSchema extends SqlContentEntityStorageSchema {
protected function getEntitySchema(ContentEntityTypeInterface $entity_type, $reset = FALSE) {
$schema = parent::getEntitySchema($entity_type, $reset);
$schema['flagging']['indexes'] += [
'entity_id__uid' => [
'entity_id',
'uid',
],
];
return $schema;
}
}