mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-19 06:43:45 +02:00
Fix tests
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
|
||||
namespace Pterodactyl\Services\Databases;
|
||||
|
||||
use Pterodactyl\Models\Database;
|
||||
use Illuminate\Database\DatabaseManager;
|
||||
use Illuminate\Contracts\Encryption\Encrypter;
|
||||
use Pterodactyl\Extensions\DynamicDatabaseConnection;
|
||||
@@ -95,7 +96,7 @@ class DatabaseManagementService
|
||||
$this->database->commit();
|
||||
} catch (\Exception $ex) {
|
||||
try {
|
||||
if (isset($database)) {
|
||||
if (isset($database) && $database instanceof Database) {
|
||||
$this->repository->dropDatabase($database->database);
|
||||
$this->repository->dropUser($database->username, $database->remote);
|
||||
$this->repository->flush();
|
||||
|
||||
Reference in New Issue
Block a user