You are here

public function MediaRevisionRevertForm::getCancelUrl in Media Revisions UI 2.0.x

Same name and namespace in other branches
  1. 8 src/Form/MediaRevisionRevertForm.php \Drupal\media_revisions_ui\Form\MediaRevisionRevertForm::getCancelUrl()

Returns the route to go to if the user cancels the action.

Return value

\Drupal\Core\Url A URL object.

Overrides ConfirmFormInterface::getCancelUrl

File

src/Form/MediaRevisionRevertForm.php, line 91

Class

MediaRevisionRevertForm
Provides a form for reverting media revision.

Namespace

Drupal\media_revisions_ui\Form

Code

public function getCancelUrl() {
  return new Url('entity.media.version_history', [
    'media' => $this->revision
      ->id(),
  ]);
}