function lightning_core_update_8002 in Lightning Core 8.4
Same name and namespace in other branches
- 8.5 lightning_core.install \lightning_core_update_8002()
- 8 lightning_core.install \lightning_core_update_8002()
- 8.2 lightning_core.install \lightning_core_update_8002()
- 8.3 lightning_core.install \lightning_core_update_8002()
Marks certain node view modes as internal.
1 call to lightning_core_update_8002()
- lightning_core_install in ./
lightning_core.install - Implements hook_install().
File
- ./
lightning_core.install, line 59 - Contains install and update routines for Lightning.
Code
function lightning_core_update_8002() {
$view_modes = EntityViewMode::loadMultiple([
'node.rss',
'node.search_index',
]);
/** @var \Drupal\Core\Entity\EntityViewModeInterface $view_mode */
foreach ($view_modes as $view_mode) {
$view_mode
->setThirdPartySetting('lightning_core', 'internal', TRUE)
->save();
}
}