6fd7c78f0c
This action allows servers to be deleted, but only be soft-deleted for 10 minutes. After that time period the server will be completely removed from the database and daemon. This allows some safety if a server is accidentally deleted. Force deleting a server will still work. If the daemon is in-accessible the server will fail to be deleted. When server is soft-deleted admins can still view its information page in the admin CP, however the server will be suspended and inaccessible on the front-end or though the daemon. Admins can manually delete the server ahead of the delete timer, or if it failed to delete previously they can do an immediate retry.
32 lines
641 B
PHP
32 lines
641 B
PHP
<?php
|
|
|
|
namespace Pterodactyl\Providers;
|
|
|
|
use Illuminate\Support\Facades\Event;
|
|
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
|
|
|
|
class EventServiceProvider extends ServiceProvider
|
|
{
|
|
/**
|
|
* The event listener mappings for the application.
|
|
*
|
|
* @var array
|
|
*/
|
|
protected $listen = [
|
|
'Pterodactyl\Events\ServerDeleted' => [
|
|
'Pterodactyl\Listeners\DeleteServerListener',
|
|
],
|
|
];
|
|
|
|
/**
|
|
* Register any other events for your application.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function boot()
|
|
{
|
|
parent::boot();
|
|
|
|
//
|
|
}
|
|
}
|