You are here

function paragraphs_update_8007 in Paragraphs 8

Ensure that existing paragraphs are published.

File

./paragraphs.install, line 149
Installation hooks for Paragraphs module.

Code

function paragraphs_update_8007() {
  \Drupal::database()
    ->update('paragraphs_item_field_data')
    ->fields([
    'status' => 1,
  ])
    ->isNull('status')
    ->execute();
  \Drupal::database()
    ->update('paragraphs_item_revision_field_data')
    ->fields([
    'status' => 1,
  ])
    ->isNull('status')
    ->execute();
}