bash/snippets/dokuwiki-2023-04-04/inc/Action/Cancel.php

29 lines
460 B
PHP

<?php
namespace dokuwiki\Action;
use dokuwiki\Action\Exception\ActionAbort;
/**
* Class Cancel
*
* Alias for show. Aborts editing
*
* @package dokuwiki\Action
*/
class Cancel extends AbstractAliasAction {
/**
* @inheritdoc
* @throws ActionAbort
*/
public function preProcess() {
global $ID;
unlock($ID);
// continue with draftdel -> redirect -> show
throw new ActionAbort('draftdel');
}
}