You are here

function feeds_update_8002 in Feeds 8.3

Installs new table 'feeds_clean_list'.

File

./feeds.install, line 52
Install/update/uninstall hooks.

Code

function feeds_update_8002() {
  $database = \Drupal::database();
  $schema = $database
    ->schema();
  if (!$schema
    ->tableExists('feeds_clean_list')) {

    // Add feeds_clean_list table.
    $schema
      ->createTable('feeds_clean_list', [
      'description' => 'Keeps a list of items to clean after the process stage.',
      'fields' => [
        'feed_id' => [
          'description' => 'The ID of the feed.',
          'type' => 'int',
          'unsigned' => TRUE,
          'not null' => TRUE,
        ],
        'entity_id' => [
          'description' => 'The ID of the entity to clean.',
          'type' => 'int',
          'unsigned' => TRUE,
          'not null' => TRUE,
        ],
      ],
    ]);
  }
}