You are here

MultiversionRevisionRevertTranslationForm.php in Multiversion 8

File

src/Form/MultiversionRevisionRevertTranslationForm.php
View source
<?php

namespace Drupal\multiversion\Form;

use Drupal\Core\Form\FormStateInterface;
use Drupal\node\Form\NodeRevisionRevertTranslationForm;

/**
 * Adds a flag when the entity is reverting.
 */
class MultiversionRevisionRevertTranslationForm extends NodeRevisionRevertTranslationForm {

  /**
   * {@inheritdoc}
   */
  public function submitForm(array &$form, FormStateInterface $form_state) {
    $this->revision->is_reverting = TRUE;
    parent::submitForm($form, $form_state);
  }

}

Classes

Namesort descending Description
MultiversionRevisionRevertTranslationForm Adds a flag when the entity is reverting.