function opigno_module_update_8008 in Opigno module 8
Update view and media_browser_widget configs.
File
- ./
opigno_module.install, line 595 - Opigno module app install/update functionality.
Code
function opigno_module_update_8008() {
$config_path = drupal_get_path('module', 'opigno_module') . '/config/optional';
/* @var Drupal\Core\Config\CachedStorage $config_storage */
$storage = new FileStorage($config_path);
$config_storage = \Drupal::service('config.storage');
$configs = [
'entity_browser.browser.media_entity_browser_file_pdf',
'views.view.media_browser_file_pdf',
];
foreach ($configs as $item) {
$data = $storage
->read($item);
$config_storage
->write($item, $data);
}
}