We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0da31c3 commit d84d0a8Copy full SHA for d84d0a8
app/Jobs/DatabaseBackupJob.php
@@ -66,7 +66,12 @@ public function __construct($backup)
66
public function handle(): void
67
{
68
try {
69
- $this->team = Team::findOrFail($this->backup->team_id);
+ $this->team = Team::find($this->backup->team_id);
70
+ if (! $this->team) {
71
+ $this->backup->delete();
72
+
73
+ return;
74
+ }
75
if (data_get($this->backup, 'database_type') === 'App\Models\ServiceDatabase') {
76
$this->database = data_get($this->backup, 'database');
77
$this->server = $this->database->service->server;
0 commit comments