Cleanup auto-deployment functions substantially
Also cleans up ServerRepository to use named models more clearly.
This commit is contained in:
parent
c59cfce72c
commit
b3e5565f85
4 changed files with 273 additions and 115 deletions
|
@ -34,6 +34,7 @@ use Pterodactyl\Exceptions\DisplayException;
|
|||
use Pterodactyl\Http\Controllers\Controller;
|
||||
use Pterodactyl\Repositories\ServerRepository;
|
||||
use Pterodactyl\Repositories\DatabaseRepository;
|
||||
use Pterodactyl\Exceptions\AutoDeploymentException;
|
||||
use Pterodactyl\Exceptions\DisplayValidationException;
|
||||
|
||||
class ServersController extends Controller
|
||||
|
@ -97,6 +98,8 @@ class ServersController extends Controller
|
|||
return redirect()->route('admin.servers.new')->withErrors(json_decode($ex->getMessage()))->withInput();
|
||||
} catch (DisplayException $ex) {
|
||||
Alert::danger($ex->getMessage())->flash();
|
||||
} catch (AutoDeploymentException $ex) {
|
||||
Alert::danger('Auto-Deployment Exception: ' . $ex->getMessage())->flash();
|
||||
} catch (TransferException $ex) {
|
||||
Log::warning($ex);
|
||||
Alert::danger('A TransferException was encountered while trying to contact the daemon, please ensure it is online and accessible. This error has been logged.')->flash();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue