Skip to content

Commit

Permalink
FIX Remove broken restore batch action
Browse files Browse the repository at this point in the history
  • Loading branch information
emteknetnz committed May 9, 2024
1 parent 117dc25 commit 687c69c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 9 additions & 0 deletions code/BatchActions/CMSBatchAction_Restore.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,21 @@
use SilverStripe\ORM\SS_List;
use SilverStripe\Versioned\Versioned;
use SilverStripe\Security\Permission;
use SilverStripe\Dev\Deprecation;

/**
* Batch restore of pages
*
* @deprecated 5.3.0 Will be removed without equivalent functionality to replace it
*/
class CMSBatchAction_Restore extends CMSBatchAction
{
public function __construct()
{
Deprecation::withNoReplacement(function () {
Deprecation::notice('5.3.0', 'Will be removed without equivalent functionality to replace it', Deprecation::SCOPE_CLASS);
});
}

public function getActionTitle()
{
Expand Down
2 changes: 0 additions & 2 deletions code/Controllers/CMSMain.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
use SilverStripe\Admin\Navigator\SilverStripeNavigator;
use SilverStripe\CMS\BatchActions\CMSBatchAction_Archive;
use SilverStripe\CMS\BatchActions\CMSBatchAction_Publish;
use SilverStripe\CMS\BatchActions\CMSBatchAction_Restore;
use SilverStripe\CMS\BatchActions\CMSBatchAction_Unpublish;
use SilverStripe\CMS\Controllers\CMSSiteTreeFilter_Search;
use SilverStripe\CMS\Model\CurrentPageIdentifier;
Expand Down Expand Up @@ -188,7 +187,6 @@ protected function init()

Requirements::add_i18n_javascript('silverstripe/cms: client/lang', false);

CMSBatchActionHandler::register('restore', CMSBatchAction_Restore::class);
CMSBatchActionHandler::register('archive', CMSBatchAction_Archive::class);
CMSBatchActionHandler::register('unpublish', CMSBatchAction_Unpublish::class);
CMSBatchActionHandler::register('publish', CMSBatchAction_Publish::class);
Expand Down

0 comments on commit 687c69c

Please sign in to comment.