Skip to content

Commit

Permalink
Added update for empty behaviour upadte patch.
Browse files Browse the repository at this point in the history
Renamed yml file.
  • Loading branch information
arshadkhan53 committed Sep 17, 2020
1 parent 2277f1b commit 0ff6119
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 0 deletions.
16 changes: 16 additions & 0 deletions config/update/ezcontent_publish_update_8001.yml
@@ -0,0 +1,16 @@
views.view.content:
expected_config:
display:
default:
display_options:
fields:
moderation_state:
empty: ''
update_actions:
change:
display:
default:
display_options:
fields:
moderation_state:
empty: 'N/A'
20 changes: 20 additions & 0 deletions ezcontent_publish.install
@@ -0,0 +1,20 @@
<?php

/**
* @file
* Install file for ezcontent_publish.
*/

/**
* Added empty result behaviour for moderation state.
*/
function ezcontent_publish_update_8001() {
/** @var \Drupal\update_helper\Updater $updateHelper */
$updateHelper = \Drupal::service('update_helper.updater');

// Execute configuration update definitions with logging of success.
$updateHelper->executeUpdate('ezcontent_publish', 'ezcontent_publish_update_8001');

// Output logged messages to related channel of update execution.
return $updateHelper->logger()->output();
}

0 comments on commit 0ff6119

Please sign in to comment.