increase test coverage (#117)

70% test coverage
remove socialite
This commit is contained in:
Saeed Vaziry
2024-03-15 22:23:45 +01:00
committed by GitHub
parent 4f12de9586
commit a406491160
62 changed files with 1102 additions and 639 deletions

View File

@ -0,0 +1,21 @@
<?php
namespace App\Actions\StorageProvider;
use App\Models\StorageProvider;
use Exception;
class DeleteStorageProvider
{
/**
* @throws Exception
*/
public function delete(StorageProvider $storageProvider): void
{
if ($storageProvider->backups()->exists()) {
throw new Exception('This storage provider is being used by a backup.');
}
$storageProvider->delete();
}
}