function RevisionRevertForm::getQuestion

Same name in other branches
  1. 10 core/lib/Drupal/Core/Entity/Form/RevisionRevertForm.php \Drupal\Core\Entity\Form\RevisionRevertForm::getQuestion()

Overrides ConfirmFormInterface::getQuestion

File

core/lib/Drupal/Core/Entity/Form/RevisionRevertForm.php, line 112

Class

RevisionRevertForm
Provides a form for reverting an entity revision.

Namespace

Drupal\Core\Entity\Form

Code

public function getQuestion() {
    return $this->getEntity() instanceof RevisionLogInterface ? $this->t('Are you sure you want to revert to the revision from %revision-date?', [
        '%revision-date' => $this->dateFormatter
            ->format($this->getEntity()
            ->getRevisionCreationTime()),
    ]) : $this->t('Are you sure you want to revert the revision?');
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.