<?php
|
|
|
|
namespace App\Menus\Nginx;
|
|
|
|
use PhpSchool\CliMenu\CliMenu;
|
|
use App\Facades\NginxVhost;
|
|
use App\Facades\NginxVhostFactory;
|
|
|
|
/**
|
|
* Action that override default-action for go back
|
|
* reload vhosts
|
|
*
|
|
* @author Björn Hase, Tentakelfabrik
|
|
* @license http://opensource.org/licenses/MIT The MIT License
|
|
* @link https://gitea.tentakelfabrik.de/Tentakelfabrik/mcp
|
|
*
|
|
*/
|
|
class NginxVhostCancelAction
|
|
{
|
|
/**
|
|
*
|
|
* @param CliMenu $menu [description]
|
|
* @return [type] [description]
|
|
*/
|
|
public function __invoke(CliMenu $menu): void
|
|
{
|
|
$parent = $menu->getParent();
|
|
$menu->closeThis();
|
|
|
|
$parent->open();
|
|
}
|
|
}
|