public function DevelEntityUpdatesCommands::entityUpdates in Devel Entity Updates 8
Same name and namespace in other branches
- 8.2 src/Commands/DevelEntityUpdatesCommands.php \Drupal\devel_entity_updates\Commands\DevelEntityUpdatesCommands::entityUpdates()
- 3.x src/Commands/DevelEntityUpdatesCommands.php \Drupal\devel_entity_updates\Commands\DevelEntityUpdatesCommands::entityUpdates()
- 3.0.x src/Commands/DevelEntityUpdatesCommands.php \Drupal\devel_entity_updates\Commands\DevelEntityUpdatesCommands::entityUpdates()
Apply pending entity schema updates.
@command devel-entity-updates @aliases dentup, entup, entity-updates @option cache-clear Set to 0 to suppress normal cache clearing; the caller should then clear if needed. @bootstrap full
Parameters
array $options: Array of options.
1 call to DevelEntityUpdatesCommands::entityUpdates()
- DevelEntityUpdatesCommands::doLegacyEntityUpdates in src/
Commands/ DevelEntityUpdatesCommands.php - Replaces the "entity-updates" command.
File
- src/
Commands/ DevelEntityUpdatesCommands.php, line 56
Class
- DevelEntityUpdatesCommands
- Drush9 commands definitions.
Namespace
Drupal\devel_entity_updates\CommandsCode
public function entityUpdates($options = [
'cache-clear' => TRUE,
]) {
if (Drush::simulate()) {
throw new \Exception(dt('entity-updates command does not support --simulate option.'));
}
if ($this
->doEntityUpdates() === FALSE) {
return;
}
if (!empty($options['cache-clear'])) {
drush_drupal_cache_clear_all();
}
$this
->logger()
->success(dt('Finished performing updates.'));
}