Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. SaveAction.php

function SaveAction::execute

Overrides ExecutableInterface::execute

File

core/lib/Drupal/Core/Action/Plugin/Action/SaveAction.php, line 65

Class

SaveAction
Provides an action that can save any entity.

Namespace

Drupal\Core\Action\Plugin\Action

Code

public function execute($entity = NULL) {
    $entity->setChangedTime($this->time
        ->getRequestTime())
        ->save();
}
RSS feed
Powered by Drupal