mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-11 02:43:45 +02:00
Add support for deleting service packs.
This commit is contained in:
@@ -225,4 +225,13 @@ class Pack
|
||||
});
|
||||
}
|
||||
|
||||
public function delete($id) {
|
||||
$pack = Models\ServicePack::findOrFail($id);
|
||||
// @TODO Check for linked servers; foreign key should block this.
|
||||
DB::transaction(function () use ($pack) {
|
||||
$pack->delete();
|
||||
Storage::deleteDirectory('packs/' . $pack->uuid);
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user