Update to Drupal 8.2.2. For more information, see https://www.drupal.org/project/drupal/releases/8.2.2
This commit is contained in:
parent
23ffed3665
commit
507b45a0ed
378 changed files with 11434 additions and 5542 deletions
|
@ -876,8 +876,12 @@ abstract class EntityDisplayFormBase extends EntityForm {
|
|||
protected function saveDisplayStatuses($display_statuses) {
|
||||
$displays = $this->getDisplays();
|
||||
foreach ($displays as $display) {
|
||||
$display->set('status', $display_statuses[$display->get('mode')]);
|
||||
$display->save();
|
||||
// Only update the display if the status is changing.
|
||||
$new_status = $display_statuses[$display->get('mode')];
|
||||
if ($new_status !== $display->status()) {
|
||||
$display->set('status', $new_status);
|
||||
$display->save();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Reference in a new issue